Skip to content

docs(skill): document ctx.input, drop daemon teaching, prune platform-tool prose#22

Merged
basedfriday merged 3 commits into
mainfrom
skill/sharpen-python-agent-authoring
May 15, 2026
Merged

docs(skill): document ctx.input, drop daemon teaching, prune platform-tool prose#22
basedfriday merged 3 commits into
mainfrom
skill/sharpen-python-agent-authoring

Conversation

@basedfriday
Copy link
Copy Markdown
Contributor

Summary

Sharpens the writing-friday-python-agents skill so it teaches authoring well and stops at the SDK boundary.

  • ctx.input is now documented in references/api.md. Previously SKILL.md teased it as a first-class capability (the v0.1.8 feature) but the API reference had no ## ctx.input section. All four AgentInput methods are now spelled out, plus InputArtifactRef. Also filled in the previously-missing public exports (AgentInput, SkillDefinition, Http, Llm, Tools, SessionData, ToolDefinition, AgentExtras, ArtifactRef, OutlineRef).
  • New Tier 6 example for inputFrom consumption showing the workspace.yml FSM wiring plus the consumer agent.py using ctx.input.get with an artifact_json fallback. Closes the gap where models knew the API existed but had no end-to-end pattern to mimic.
  • Removed daemon-teaching from the SDK skill. The "Register via the daemon HTTP API" block (curl http://localhost:8080/api/agents/register) and the "Test directly" curl examples are out. Replaced with a "Getting Agents Into a Workspace" section that points at the host platform's own tooling and keeps only the workspace.yml snippet. The "atlas agent register" build-pipeline section is gone from constraints.md. The SDK shouldn't be telling agents how to talk to a daemon, and the hardcoded localhost:8080 was wrong for any TLS-enabled install anyway.
  • Documented output_schema and use_workspace_skills. Both decorator params were listed without semantics in api.md; now each has a short section explaining what surfaces at runtime (ctx.output_schema, ctx.skills).
  • Pruned platform-tool prose from SKILL.md. The request_human_input and save_memory_entry / list_memory_entries sections are gone — those tools come from the host platform, not the SDK, and platform-tool guidance lives in the host platform's own skill. Replaced with a one-paragraph "Platform-injected tools" pointer reminding callers to ctx.tools.list() and check platform docs.
  • Consolidated input handling into a 2-column table (signal payload via prompt vs upstream-step output via ctx.input) so the model can navigate by use case instead of by SDK surface.

Test plan

  • Render SKILL.md and the three reference files — confirm headings line up with their tables of contents.
  • grep -r "localhost:8080\|localhost:5200\|FRIDAYD_URL\|/api/agents/register\|atlas agent register" packages/python/skills/writing-friday-python-agents/ returns nothing.
  • Spot-check that ctx.input signatures match friday_agent_sdk/_types.py::AgentInput.
  • Sanity-check the Tier 6 example compiles / matches actual inputFrom semantics.

…-tool prose

- api.md: add ctx.input section with AgentInput method signatures
  (get/require/artifact_refs/artifact_json) and InputArtifactRef; fill in
  previously-missing public exports (AgentInput, SkillDefinition, Http, Llm,
  Tools, SessionData, ToolDefinition, AgentExtras, ArtifactRef, OutlineRef);
  describe output_schema and use_workspace_skills semantics; add skills field
  and SkillDefinition block to AgentContext.

- examples.md: new Tier 6 covering upstream-step output consumption via
  ctx.input.get / ctx.input.artifact_json, with the workspace.yml FSM wiring
  that populates it.

- SKILL.md: replace the "register via the daemon HTTP API" block with a
  workspace-integration section that points to platform tooling and keeps
  only the workspace.yml snippet. Remove request_human_input /
  save_memory_entry sections — platform-tool guidance belongs in the host
  platform's own skill, not the SDK skill. Consolidate the input-handling
  intro into a signal-payload-vs-inputFrom table for clearer model steering.

- constraints.md: drop the "atlas agent register" build-pipeline section so
  the skill no longer teaches daemon plumbing.
…v var

Review found two factual errors in the prior commits:

- output_schema/input_schema decorator kwargs were documented as
  dataclass-to-JSON-Schema conversion that ships to the host. The bridge
  never assigns the *_json_schema registry fields, so the dataclass is
  silently dropped — the feature is unimplemented. Drop the schema-extraction
  narrative from api.md and constraints.md; mention both kwargs are accepted
  but no-op today. Re-describe ctx.output_schema as host-driven (sourced from
  raw["output_schema"] on the execute payload), since that is what the runtime
  actually populates.

- SKILL.md claimed the host sets FRIDAY_NATS_URL; the SDK reads NATS_URL
  (_bridge.py and tests). Fixed.

Also: tighten Tier 6 dict guard to isinstance(payload, dict) so the example
doesn't TypeError on non-container payloads; add __version__ to Public
Exports list; add a one-line note explaining where AgentInput.raw comes from
(the host's execute payload).
@basedfriday basedfriday merged commit 5289ebc into main May 15, 2026
9 checks passed
@basedfriday basedfriday deleted the skill/sharpen-python-agent-authoring branch May 15, 2026 04:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant