feat: agents add + templates show - #106
Merged
Merged
Conversation
- templates.rs: port all 6 agent template bodies from v0 (default/minimal/voice-only/text-only/customer-service/assistant) and template_by_name(). The large default template is parsed from a raw JSON string rather than the json! macro (the macro's recursion limit is exceeded and #![recursion_limit] can only live in the generated crate root). Add `agents templates show <template>`. - agents add: create an agent from a template or --from-file, upload it via the raw-JSON API (lossless), write the config to agent_configs/, and register it in agents.json. Ports v0's add.ts (incl. --output-path, --from-file/--template mutual exclusion, name resolution). - README: document `agents add` and `templates show`. - Unit tests for every template + template_by_name. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Switch the default TTS model in all agent templates from the deprecated eleven_turbo_v2 to eleven_flash_v2_5. No template references a turbo model anymore. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Continues the v0 → v1 agents-as-code port (follows #105).
agents add— create an agent from a template (--template) or an existing config file (--from-file), upload it to ElevenLabs via the lossless raw-JSON API, write the config toagent_configs/, and register it inagents.json. Ports v0'sadd.tsincluding--output-path,--from-file/--templatemutual exclusion, and name resolution (explicit name overrides the file's name).agents templates show <template>— print a template's full configuration.default,minimal,voice-only,text-only,customer-service,assistant) +template_by_name(), soadd/templatesproduce byte-for-byte the same configs as v0.Implementation note
The large
defaulttemplate is parsed from a raw JSON string rather than thejson!macro — the macro exceeds its recursion limit on a structure this deep, and#![recursion_limit]can only live in the (generated) crate root.Verified
cargo buildgreen; 11 unit tests pass (project + api + templates). Smoke-tested:templates show <name>renders each template;addvalidation paths (mutual exclusion, missing name) error correctly. (Theaddcreate call itself needs a live API key/account to exercise end-to-end.)Not yet included (follow-ups)
agents push/pull/test+ verify, thetools/testscommand groups,residencyandcomponents add.🤖 Generated with Claude Code