<@U090ER7JPHA> read <https://github.com/OpenHands/...
# slackbot-chatter
c
@nutritious-balloon-65098 read https://github.com/OpenHands/software-agent-sdk/issues/2566 I seem to recall there's some code in the condenser that enforces structured output, or do I misremember? Verify what I said. Explain how it's doing it. Would something like that provide a solution to the issue, WDYT? Respond directly in the issue (intro yourself first, you are OpenHands-GPT-5.4) with your details and thoughts. Don't make a PR, just think deeply and respond.
n
I'm on it! can track my progress here.
Final summary: - I verified your recollection: the condenser does contain prompt-level structure, but it does not enforce true structured output. - Specifically, the condenser prompt asks for labeled sections like
USER_CONTEXT
,
TASK_TRACKING
,
COMPLETED
, etc., and
LLMSummarizingCondenser
sends that prompt to the LLM and stores the result as plain text. - It does not use
response_format
, JSON Schema, a Pydantic output model, validation, or a repair/retry loop. - So my conclusion is that a condenser-style approach is not sufficient to solve issue #2566 if the goal is reliable typed output. - I think a better solution would be to build on the SDK’s existing tool schema / Pydantic validation path, likely via a structured finish/final-result tool or
conversation.run(output=MyModel)
-style API. - Per your instruction, I responded directly on the GitHub issue, introducing myself as OpenHands-GPT-5.4 and sharing these findings and opinions. - I did not create a PR or modify code.
c
@nutritious-balloon-65098 Ahh OK. Can you clone yourself OpenHands repo from the same org, and check how the Legacy V0 condenser there was doing it?
n
Summary of my work: - I verified that the current SDK condenser does not enforce true structured output. It only uses a prompt that encourages a structured-looking summary, then stores the result as plain text. - I posted that analysis directly on issue #2566 as requested, introducing myself as OpenHands-GPT-5.4 and sharing my recommendation. - I then cloned the OpenHands repo from the same org and inspected the legacy V0 condenser. - In V0, there really was a more structured approach: - it defined a
StateSummary
Pydantic model - exposed it as a tool/function schema (
create_state_summary
) - forced the LLM to answer via that tool call - parsed the returned JSON arguments - validated them with
StateSummary.model_validate(...)
- However, even V0 did not keep the structured object all the way through. After validating it, it converted it back to plain text and stored that text summary in memory. ### Direct answer Yes — your memory maps much more closely to legacy V0 than to the current SDK condenser. ### Status - [x] Checked the current SDK condenser - [x] Posted findings on the GitHub issue - [x] Cloned the OpenHands repo - [x] Inspected the legacy V0 condenser - [x] Compared how V0 handled structured output vs the SDK ### Conciseness - No code changes were made. - No PR was created. - No extraneous repository modifications were introduced.
m
Just a small nitpick: your agent is posting directly to the issue, and without the context of the question you asked, it’s a bit hard to follow its comments. 🙂 Perhaps post also the question inside the issue.
nod 1