multica-creating-agents
multica-ai/multica
`multica agent` CLI 또는 `POST /api/agents`를 통해 Multica 에이전트를 생성, 확인 또는 디버깅할 때 사용합니다. — 각 필드의 정의, 저장되는 형식, 메타데이터 전용인지 또는 클레임 시점에 데몬에 의해 소비되는지 여부, 어떤 입력값이 유효한지/거부되는지, custom_env 시크릿이 어떻게 제어되는지, 스킬 바인딩이 어떻게 작동하는지 등을 확인하는 데 사용하십시오. 기존 에이전트에 이슈를 할당하거나 런타임 작업 프롬프트에는 사용하지 마십시오.
...모든 것을 확장하십시오Multica 에이전트 생성
이 문서는 Multica의 에이전트 생성 경로에 대한 계약서입니다. 여기에는 생성 엔트리
포인트가 허용하는 내용, 서버가 유효성을 검증하고 거부하는 사항, 각 필드가
어떻게 저장되는지, 그리고 클레임 시점에 데몬이 실제로 읽는 필드가 무엇인지가
명시되어 있습니다. 이 문서는
매개변수 설명서가 아닙니다. 소스 코드를 추적하여 확인된 사실만을 기술하며, 모든 주장은
references/creating-agents-source-map.md 파일의 ‘파일:줄 번호’로 뒷받침됩니다.
빠른 시작 (읽기 전용 검사)
다음 명령어는 상태를 읽을 뿐이며, 어떠한 부수 효과도 일으키지 않습니다:
multica agent get --output json # 전체 영구 저장된 에이전트 레코드
multica agent skills list --output json # 현재 스킬 바인딩
multica agent env get --output json # 일반 텍스트 환경 변수 (소유자/관리자 전용, 에이전트는 접근 거부)
agent get 명령어는 runtime_id, model,
thinking_level, service_tier, custom_args, has_custom_env,
custom_env_key_count 및 skills를 포함한 영구 저장된 에이전트 정보를 반환합니다. 평문 형태의 custom_env는 절대 반환하지 않습니다.
핵심 모델
에이전트는 워크스페이스 범위의 행( agent 테이블)입니다. 생성은 단일
POST /api/agents 요청(multica agent create)으로 이루어집니다. 작업 청구 시점에 데몬은
에이전트 행을 다시 읽어와 런타임 페이로드를 구성합니다. 따라서 에이전트가 실행되는 기준은 생성 시점의 출력이 아닌
저장된 필드들입니다.
종종 혼동되는 두 가지 별개의 텍스트 필드:
description은카탈로그 요약입니다. 이는 저장되어 목록에 표시되며, 데몬은 이를 에이전트의 런타임 프롬프트에 주입하지 않습니다. 이를 오직 사용자를 위한 메타데이터로만 취급하십시오. 최대 255개의 유니코드 코드 포인트로 제한됩니다.instructions는런타임 동작 계약입니다. 데몬은 클레임 시점에 이를 읽어 에이전트의 영구적인 지침으로 제공자에게 전달합니다. 페르소나, 책임, 경계, 출력 및 에스컬레이션 규칙은description이아닌 이곳에 기재해야 합니다.
CLI / API 진입점
최소 생성 호출 (--name 및 --runtime-id는 모두 필수):
multica agent create --name --runtime-id \
--description "" \
--instructions "" \
--output json
runAgentCreate는 JSON 본문을 생성하여 /api/agents로 POST 요청을 보냅니다. 이 명령어는 해당 플래그가 제공된 경우에만
키를 추가합니다 —description/instructions는
빈 값이 아닌 경우 description/instructions 키를 추가하고, 나머지(runtime-config, custom-args, model,
thinking-level, service-tier, visibility, …)는 해당 플래그가 Changed일 때 추가됩니다. 따라서 생략된
플래그는 빈 문자열을 전송하는 대신 서버의 기본값으로 처리됩니다.
HTTP 본문(CreateAgentRequest)은 다음을 지원합니다: name, description,
instructions, avatar_url, runtime_id, runtime_config, custom_env,
custom_args, model, thinking_level, service_tier, visibility,
max_concurrent_tasks, mcp_config.
필드 계약
생략 시 기본값: runtime_config → {}, custom_env → {},
custom_args → [], avatar_url → 무작위 이모지:, visibility →
private, max_concurrent_tasks → 6
(모든 값은 삽입 전에 서버 측에서 구체화됨).custom_args/runtime_config
는 []string/any 유형이며 있는 그대로 마샬링됩니다 — JSON 형식에 대한 오류
검사는 create 핸들러가 아닌 CLI에서 수행됩니다.
thinking_level은 프로바이더 수준에서만 유효성 검사가 이루어집니다: 고정 카탈로그
프로바이더는 인식되지 않는 리터럴을 거부하는 반면, Codex/OpenCode와 같은
동적 카탈로그 프로바이더는 구문적으로 안전한 토큰을 허용합니다. 선택된 모델에서
지원되지 않는 값은 여기서 거부되지 않습니다 — 데몬은 실행 시점에 로컬 모델
카탈로그를 확인하고, 경고를 기록한 후 호환되지 않는 오버라이드를 생략합니다.
--model과 마찬가지로, 에이전트 생성 및 업데이트 시 CLI에서 --thinking-level을 사용하여 설정할 수 있습니다. 이 플래그는 최상위
thinking_level 필드로 직접 전달되며, 업데이트 시 빈 문자열(--thinking-level "")을
지정하면 런타임 기본값으로 재설정됩니다. CLI는 의도적으로 유효한 레벨을 열거하지 않습니다.
이 레벨들은 런타임/모델에 따라 다르기 때문입니다(Claude는 현재
low|medium|high|xhigh|max를 사용하며, Codex의 값은 런타임의
모델 카탈로그에서 확인됩니다). CLI는 토큰을 전달하면, 서버는 제공자의
고정 열거형(fixed-enum) 또는 안전 토큰(safe-token) 게이트를 적용하고, 데몬은 정확한 모델/레벨
검사를 수행합니다. 제공자에 'thinking' 개념이 없는 런타임은 비어 있지 않은
값을 400 오류로 거부합니다.
service_tier는 이에 대응하는 일급 Codex 속도 제어 기능입니다. 생성/업데이트 시
--service-tier 설정하고, 업데이트 시 --service-tier ""를
사용하여 초기화합니다. 런타임 모델 카탈로그는 가용성과
표시 사본(현재 우선순위, Fast로 표시됨)을 모두 관리합니다. 서버는 안전한
미래의 Codex 카탈로그 ID를 허용하는 반면, 데몬은 실행 전에 정확한 모델/티어 쌍을
검증하고, 오래되어 호환되지 않는 재정의는 생략합니다. 명시적인 모델이 없는
에이전트는 유효한 config.toml 모델이 알려지지 않았기 때문에 실패(closed) 처리됩니다.
model 대 custom_args
model은 데몬이 직접 읽는 1급 영구 저장 열입니다.
custom_args는 원시 프로바이더 CLI 인수입니다. CLI 도움말에 따르면 일부 프로바이더
(codex app-server, openclaw)는 custom_args 내의 --model을 거부하지만, 이는
문서화된 CLI 지침일 뿐 서버가 강제하는 불변 조건은 아닙니다. create
핸들러에는 custom_args에서 모델 플래그를 검사하는 코드가 전혀 없습니다.
환경 및 시크릿
custom_env는 시크릿 정보입니다. CLI는 세 가지 입력 채널을 제공하며, 그중 두 가지는
시크릿이 쉘 기록 및 프로세스 목록에 남지 않도록 합니다:
multica agent create --name --runtime-id --custom-env-stdin --output json
multica agent create --name --runtime-id --custom-env-file <0600-json> --output json
--custom-env-stdin은 표준 입력(stdin)에서 JSON 객체를 읽으며, --custom-env-file은
파일에서 읽습니다(권장 권한: 0600). 세 번째 방법인
--custom-env 는 쉘 히스토리
및 ps 명령어가 확인할 수 있는 명령줄에 값을 표시하므로, 실제 기밀 정보의 경우 이 방법을 피해야 합니다.
읽기 측 사실(피해야 할 잘못된 가정들):
- 에이전트 리소스는 절대
custom_env를평문으로 노출하지 않습니다.agent list/get/create/update및 WS 이벤트는has_custom_env(bool)와custom_env_key_count(int)만 반환합니다. - 일반 텍스트 값을 읽으려면 전용
GET /api/agents/{id}/env엔드포인트(multica agent env get)를 사용해야 합니다. 이 엔드포인트는 워크스페이스 소유자/관리자 구성원에게만 허용되며, 에이전트 행위자는 백엔드 구성원의 역할과 관계없이 접근이 거부됩니다. 즉, 실행 중인 에이전트는 다른 에이전트의 비밀 정보를 읽을 수 없습니다. - 생성 후 값을 쓰려면
에이전트 업데이트를통해서는 안 됩니다. 일반 업데이트 핸들러는custom_env필드가 포함된 요청을 400 오류("PUT /api/agents/{id}/env를 사용하십시오")로 거부합니다. 일반 텍스트 환경 변수 쓰기는PUT /api/agents/{id}/env(multica 에이전트 env set)를 통해 처리되며, 이는 소유자/관리자 전용이며 감사 로그를 기록합니다.
mcp_config
mcp_config는 에이전트의 MCP 서버 구성(예:
{"mcpServers": {…}}와 같은 JSON 객체)입니다. 이 또한 기밀 정보이며 — MCP 항목에는 일반적으로
API 토큰이 포함됩니다 — custom_env와 동일한 세 가지 입력 채널을 제공하며, 이는
에이전트 생성 및 에이전트 업데이트 시 모두 적용됩니다:
multica agent create --name --runtime-id --mcp-config-file <0600-json> --output json
multica agent update --mcp-config-stdin --output json
multica agent update --mcp-config 'null' # 구성을 지웁니다
--mcp-config-stdin / --mcp-config-file을 사용하면 쉘 기록
및 ps에서 값이 남지 않습니다. 반면, 인라인 --mcp-config 그렇지 않습니다. CLI는 JSON
객체나 리터럴 null을 요구합니다. 최상위 배열이나 기본형 값은
클라이언트 측에서 거부되며, 표준 입력(stdin)이나 파일 입력이 비어 있을 경우 오류가 발생하고, 아무런 메시지 없이 지워지지는 않습니다.
mcp_config가 custom_env와 다른 두 가지 점:
-
에이전트 업데이트를통해 설정할 수 있습니다.custom_env와달리mcp_config에는전용 감사 엔드포인트가 없으며, 일반적인PUT /api/agents/{id}요청으로 설정할 수 있습니다. 원시 요청 본문에 따라 세 가지 상태가 적용됩니다: 필드 생략 → 변경 없음;null→ 지우기; 객체 → 덮어쓰기. - 읽을 때 직렬화되지만, 일부 내용이 가려집니다.
에이전트get/list는에이전트 비밀 정보를 볼 수 있는 권한이 있는 호출자에게만mcp_config를반환하며, 그렇지 않은 경우 필드는null이고mcp_config_redacted는true입니다. 에이전트 액터는 이를 절대 볼 수 없으며, 워크스페이스는 모든 사용자에 대해 정보 가림을 강제할 수 있습니다.
프로바이더 지원은 일관되지 않습니다. Qwen Code는 --mcp-config 옵션으로 전달된 데몬 소유의 0600 권한 임시 JSON 파일을 통해 관리되는 mcp_config를 허용하며, 실행이 종료되면 해당 파일은 삭제됩니다. Qwen Code의 기본 설정을 상속받으려면 해당 필드를 설정하지 않은 상태(null)로 두십시오.
스킬 바인딩
에이전트를 생성한다고 해서 워크스페이스 스킬이 바인딩되는 것은 아닙니다. 바인딩은 에이전트가 생성된 후 별도의 호출을 통해 이루어집니다. 두 가지 서로 다른 동사가 있습니다:
add는추가 방식입니다 — 지정된 ID를 기존 바인딩과 병합합니다 (POST /api/agents/{id}/skills/add).set은전체 교체 방식입니다 — 지정된 ID로 바인딩 목록 전체를 정확히 덮어씁니다 (PUT /api/agents/{id}/skills);--skill-ids ''를지정하면 모두 지워집니다.
multica agent skills add --skill-ids --output json
multica agent skills list --output json
클레임 시점에 데몬은 에이전트의 스킬을 워크스페이스 바인딩 스킬로
먼저 조립한 다음, 플랫폼 내장 스킬을 추가합니다. LoadAgentSkills는 각
바인딩된 스킬의 콘텐츠와 이를 지원하는 파일을 로드합니다. 내장 스킬은
컴파일 시점에 임베드되며 SKILL.md 및 관련 파일에서 로드됩니다. 두 경우 모두
스킬 콘텐츠로 제공자에게 전달됩니다. 이것이 바로 기능이 바인딩된 스킬에 포함되어야 하고,
지침에 직접 삽입되어서는 안 되는 이유입니다.
승인이 필요한 부수 효과
읽기 전용(안전): 에이전트 가져오기, 에이전트 스킬 목록, 에이전트 환경 가져오기.
상태 변경 (명시적인 명령이 필요함 — 추측적으로 실행하지 말 것):
multica agent create— 새로운 에이전트 행을 삽입합니다.multica agent skills add/set— 바인딩을 변경합니다(set은파괴적입니다: 새 목록에 없는 바인딩은 삭제됩니다).multica agent env set— 전체custom_env맵을 덮어쓰고 감사 행을 기록합니다.
흔히 있는 잘못된 가정
- "
설명은프롬프트다." 그렇지 않습니다 — 오직명령어만이런타임에 전달됩니다. 빈 명령어를 포함한 상세한 설명은 운영 계약이 없는 명명된 셸을 생성합니다. - "생성 시 에이전트의 스킬이 바인딩된다." 그렇지 않습니다. 생성 후 명시적으로 바인딩해야 합니다.
- "
agent update가env를 교체할 수 있다." 그렇지 않습니다 —custom_env에대해 400 오류가 발생합니다; env 엔드포인트를 사용하십시오. - "
mcp_config는update 시custom_env와같은 방식으로 동작한다." 그렇지 않습니다.mcp_config는agent update(--mcp-config)를 통해 설정할 수 있으며,--mcp-config를 null로지정하면 지워집니다. 전용 env 엔드포인트 뒤에서 제어되는 것은custom_env뿐입니다. - "
agent get은env 값을 표시합니다."has_custom_env와custom_env_key_count만 표시합니다. - "생성 시 유효하지 않은
thinking_level/model조합이 감지됩니다." 오직 알 수 없는 제공자 수준 리터럴만 감지되며, 모델별 불일치는 실행 시 오류가 발생합니다. - "스킬의 경우
set과add는상호 교환 가능합니다."set은모든 바인딩을 대체합니다.add를사용하려던 상황에서 set을 사용하면 기능이 자동으로 제거됩니다.
참고 문헌
references/creating-agents-source-map.md 파일은 위의 모든 계약 사항을 현재 트리의
파일:줄 번호, 런타임 효과, 그리고 안전한 읽기 전용
검증 명령어와 매핑합니다.
Creating Multica agents
This is the contract for Multica's agent-creation path: what the create entry
points accept, what the server validates and rejects, how each field is
persisted, and which fields the daemon actually reads at claim time. It is
not a parameter manual — it states source-traced facts, and every claim is
backed by file:line in references/creating-agents-source-map.md.
Quick start (read-only inspection)
These commands read state and have no side effects:
multica agent get <agent-id> --output json # full persisted agent record
multica agent skills list <agent-id> --output json # current skill bindings
multica agent env get <agent-id> --output json # plaintext env (owner/admin only, agents denied)
agent get returns the persisted agent including runtime_id, model,
thinking_level, service_tier, custom_args, has_custom_env,
custom_env_key_count, and skills. It never returns plaintext custom_env.
Core model
An agent is a workspace-scoped row (table agent). Creation is a single
POST /api/agents (multica agent create). At task claim time the daemon
re-reads the agent row and assembles the runtime payload — so the persisted
fields, not the create-time output, are what the agent runs on.
Two distinct text fields, often confused:
descriptionis a catalog summary. It is stored and shown in listings; the daemon does NOT inject it into the agent's runtime prompt. Treat it as human-facing metadata only. Capped at 255 Unicode code points.instructionsis the runtime behavior contract. The daemon reads it at claim time and ships it to the provider as the agent's durable instructions. Persona, responsibilities, boundaries, output and escalation rules go here, not indescription.
CLI / API entry points
Minimum create call (--name and --runtime-id are both required):
multica agent create --name <name> --runtime-id <runtime-id> \
--description "<short catalog summary>" \
--instructions "<runtime behavior contract>" \
--output json
runAgentCreate builds a JSON body and posts it to /api/agents. It only
adds a key when its flag was provided — description/instructions on a
non-empty value, the rest (runtime-config, custom-args, model,
thinking-level, service-tier, visibility, …) on the flag being Changed — so omitted
flags fall through to server defaults rather than sending empty strings.
The HTTP body (CreateAgentRequest) accepts: name, description,
instructions, avatar_url, runtime_id, runtime_config, custom_env,
custom_args, model, thinking_level, service_tier, visibility,
max_concurrent_tasks, mcp_config.
Field contracts
Defaults when omitted: runtime_config → {}, custom_env → {},
custom_args → [], avatar_url → a random emoji:<glyph>, visibility →
private, max_concurrent_tasks → 6
(all materialized server-side before the insert). custom_args/runtime_config
are typed []string/any and marshaled as-is — the JSON-shape rejection
happens in the CLI, not the create handler.
thinking_level is validated only at the provider level: fixed-catalog
providers reject an unrecognized literal, while dynamic-catalog providers such
as Codex/OpenCode accept a syntactically safe token. A value unsupported for
the chosen model is NOT rejected here — the daemon checks its local model
catalog at execution time, logs a warning, and omits the incompatible override.
Set it from the CLI with --thinking-level on agent create and agent update, mirroring --model: the flag is a thin pass-through to the top-level
thinking_level field, and on update an empty string (--thinking-level "")
clears it back to the runtime default. The CLI deliberately does not enumerate
the valid levels — they are runtime/model-specific (Claude currently uses
low|medium|high|xhigh|max; Codex values are discovered from the runtime's
model catalog). It forwards the token, the server applies the provider's
fixed-enum or safe-token gate, and the daemon performs the exact model/level
check. A runtime whose provider has no thinking concept rejects any non-empty
value with a 400.
service_tier is the matching first-class Codex speed control. Set it with
--service-tier <catalog-id> on create/update; use --service-tier "" on
update to clear it. The runtime model catalog owns both availability and
display copy (currently priority, shown as Fast). The server accepts safe
future Codex catalog IDs, while the daemon verifies the exact model/tier pair
before execution and omits a stale incompatible override. Agents without an
explicit model fail closed because the effective config.toml model is unknown.
model vs custom_args
model is a first-class persisted column the daemon reads directly.
custom_args are raw provider CLI args. The CLI help notes that some providers
(codex app-server, openclaw) reject --model inside custom_args — but that is
documented CLI guidance, not a server-enforced invariant; nothing in the create
handler inspects custom_args for a model flag.
Env & secrets
custom_env is secret material. The CLI offers three input channels; two keep
secrets out of shell history and the process list:
multica agent create --name <name> --runtime-id <runtime-id> --custom-env-stdin --output json
multica agent create --name <name> --runtime-id <runtime-id> --custom-env-file <0600-json> --output json
--custom-env-stdin reads the JSON object from stdin; --custom-env-file
reads it from a file (suggested mode 0600). The third channel,
--custom-env <json>, puts the value on the command line where shell history
and ps can see it — avoid it for real secrets.
Read-side facts (these are the wrong assumptions to avoid):
- Agent resources never expose plaintext
custom_env.agent list/get/create/updateand WS events return onlyhas_custom_env(bool) andcustom_env_key_count(int). - Reading plaintext values requires the dedicated
GET /api/agents/{id}/envendpoint (multica agent env get). It is gated to workspace owner/admin members, and agent actors are denied regardless of the backing member's role — a running agent cannot read another agent's secrets. - Writing values after creation does NOT go through
agent update. The generic update handler rejects anycustom_envfield with a 400 ("use PUT /api/agents/{id}/env"). Plaintext env writes are handled byPUT /api/agents/{id}/env(multica agent env set), which is owner/admin-only and writes an audit row.
mcp_config
mcp_config is the agent's MCP server configuration (a JSON object such as
{"mcpServers": {…}}). It is also secret material — MCP entries routinely embed
API tokens — and offers the same three input channels as custom_env, on BOTH
agent create and agent update:
multica agent create --name <name> --runtime-id <runtime-id> --mcp-config-file <0600-json> --output json
multica agent update <agent-id> --mcp-config-stdin --output json
multica agent update <agent-id> --mcp-config 'null' # clears the config
--mcp-config-stdin / --mcp-config-file keep the value out of shell history
and ps; the inline --mcp-config <json> does not. The CLI requires a JSON
object or the literal null; a top-level array or primitive is rejected
client-side, and empty stdin/file input errors rather than silently clearing.
Two ways mcp_config differs from custom_env:
- It IS settable through
agent update. Unlikecustom_env,mcp_confighas no dedicated audited endpoint — the genericPUT /api/agents/{id}accepts it. Tri-state per the raw request body: field omitted → no change;null→ clear; object → replace. - It is serialized on read, but redacted.
agent get/listreturnmcp_configonly to callers allowed to view agent secrets; otherwise the field isnullandmcp_config_redactedistrue. Agent actors never see it, and a workspace may force redaction for everyone.
Provider support is not uniform: Qwen Code accepts a managed mcp_config through a daemon-owned 0600 temporary JSON file passed with --mcp-config; it is removed when the run exits. Leave the field unset (null) to inherit Qwen Code native settings.
Skill binding
Creating an agent does NOT bind any workspace skill — binding is a separate call after the agent exists. Two distinct verbs:
addis additive — it merges the given ids with existing bindings (POST /api/agents/{id}/skills/add).setis replace-all — it overwrites the entire binding list with exactly the given ids (PUT /api/agents/{id}/skills);--skill-ids ''clears all.
multica agent skills add <agent-id> --skill-ids <skill-id> --output json
multica agent skills list <agent-id> --output json
At claim time the daemon assembles the agent's skills as workspace-bound skills
FIRST, then appends the platform built-in skills. LoadAgentSkills loads each
bound skill's content plus its supporting files; built-in skills are embedded
at compile time and loaded from SKILL.md + sibling files. Both reach the
provider as skill content — which is why capability belongs in a bound skill,
not pasted into instructions.
Side effects needing approval
Read-only (safe): agent get, agent skills list, agent env get.
State-changing (require an explicit instruction — do not run speculatively):
multica agent create— inserts a new agent row.multica agent skills add/set— mutate bindings (setis destructive: it drops bindings not in the new list).multica agent env set— overwrites the fullcustom_envmap and writes an audit row.
Common wrong assumptions
- "
descriptionis the prompt." It is not — onlyinstructionsreaches the runtime. A rich description with empty instructions yields a named shell with no operating contract. - "Create binds the agent's skills." It does not; bind explicitly afterward.
- "
agent updatecan rotate env." It cannot — it 400s oncustom_env; use the env endpoint. - "
mcp_configbehaves likecustom_envon update." It does not —mcp_configIS settable viaagent update(--mcp-config), with--mcp-config nullto clear; onlycustom_envis gated behind the dedicated env endpoint. - "
agent getshows env values." It shows onlyhas_custom_envandcustom_env_key_count. - "An invalid
thinking_level/modelcombo is caught at create." Only an unknown provider-level literal is — model-specific gaps fail at run time. - "
setandaddare interchangeable for skills."setreplaces all bindings; using it when you meantaddsilently removes capabilities.
References
references/creating-agents-source-map.md maps every contract above to its
file:line on the current tree, the runtime effect, and a safe read-only
verification command.
모든 파일
0개 파일multica-creating-agents 설치
스킬 파일을 다운로드하여 .claude/skills/ 디렉터리에 압축을 풀어주세요.
ZIP 다운로드저장소를 클론하고 스킬 파일을 프로젝트에 복사하세요.
git clone https://github.com/multica-ai/multica/tree/main/server/internal/service/builtin_skills/multica-creating-agents # Copy the skill folder to .claude/skills/ or .codex/skills/
복사





집
