Skip to content

Document sub-agent condenser frontmatter - #1199

Open
cbagwell wants to merge 1 commit into
OpenHands:mainfrom
cbagwell:fix/7133-subagent-condenser-frontmatter
Open

cbagwell wants to merge 1 commit into
OpenHands:mainfrom
cbagwell:fix/7133-subagent-condenser-frontmatter

Conversation

@cbagwell

@cbagwell cbagwell commented Nov 28, 2026 •

Copy link
Copy Markdown
Contributor

This PR was created by an AI agent (OpenHands) on behalf of @cbagwell.

  • I have read and reviewed the documentation changes to the best of my ability.
  • If the change is significant, I have run the documentation site locally and confirmed it renders as expected.

Summary of changes

The file-based agent guide listed the frontmatter fields but never documented
condenser, so tuning a sub-agent's context window was undiscoverable. This adds:

  • condenser to the Frontmatter Fields table in sdk/guides/agent-file-based.mdx.
  • An Advanced Features → Condenser section covering:
    • the default LLMSummarizingCondenser (max_size=80, keep_first=4, using the
      agent's own LLM);
    • the tuning mapping (max_size, keep_first, max_tokens, enabled) with a YAML
      example;
    • disabling condensation (none / false / {enabled: false});
    • full specs with a dedicated summarizer llm;
    • the AgentDefinitionError behavior for invalid mappings (names the file and field).

Companion to OpenHands/software-agent-sdk#7181, which implements this frontmatter form
(fixes OpenHands/software-agent-sdk#7133).

Validation

  • npx mint broken-links → no broken links found.
  • npx mint dev → sdk/guides/agent-file-based renders (HTTP 200); the new section and
    YAML example are present in the rendered page.
  • uv run --with pytest --with requests --with pyyaml pytest -q tests/ → 35 passed,
    2 errors in tests/test_pricing_documentation.py, both pre-existing: the fixture fetches
    OpenHands/OpenHands/main/openhands/utils/llm.py, which now returns 404.

This change was generated by an AI agent (OpenHands) on behalf of @cbagwell.

The file-based agent guide listed the frontmatter fields but never documented condenser, so users could not discover how to tune a sub-agent's context window. Add the field to the reference table and an Advanced Features section covering the default 80/4 LLMSummarizingCondenser, the tuning keys (max_size, keep_first, max_tokens, enabled), disabling condensation, full specs with a dedicated summarizer LLM, and the AgentDefinitionError behavior for invalid mappings.

Companion to OpenHands/software-agent-sdk#7181 (fixes OpenHands/software-agent-sdk#7133).

Co-authored-by: openhands <openhands@all-hands.dev>
@mintlify

mintlify Bot commented Nov 28, 2026

Copy link
Copy Markdown
Contributor

Preview approval required

This pull request comes from a fork, so Mintlify won't build a preview until someone with write access approves commit a60a4d6.

Approve preview

@cbagwell
cbagwell marked this pull request as ready for review November 28, 2026 03:19

This branch has not been deployed

No deployments
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.

[Bug]: Sub-agents cannot tune their condenser — frontmatter mapping fails validation and the definition is silently dropped

1 participant