Skip to content

Enhance Draft Test Functionality in Agent Module#1

Closed
haasonsaas wants to merge 1 commit into
mainfrom
agent/draft-test
Closed

Enhance Draft Test Functionality in Agent Module#1
haasonsaas wants to merge 1 commit into
mainfrom
agent/draft-test

Conversation

@haasonsaas

Copy link
Copy Markdown
Contributor

This PR improves the draft test capabilities in the agent module, ensuring more accurate and efficient processing of drafts.

@cursor

cursor Bot commented Jun 21, 2026

Copy link
Copy Markdown

PR Summary

Low Risk
Documentation-only addition with no runtime, auth, or data impact.

Overview
Adds a single new file TEST_BRANCH_MARKER.md containing only a # test heading. Nothing else in the repo references it; it reads like a branch or draft-PR marker for tooling or experiments rather than a product change.

Reviewed by Cursor Bugbot for commit dad2993. Bugbot is set up for automated code reviews on this repo. Configure here.

@haasonsaas haasonsaas closed this Jun 21, 2026
@haasonsaas haasonsaas deleted the agent/draft-test branch June 21, 2026 01:16
haasonsaas added a commit that referenced this pull request Jun 21, 2026
…a to model

Two wiring bugs that prevented the runtime from working against a real
provider, found by running summarize.act against OpenRouter:

1. The `using <alias>` handle (e.g. "coder") was sent to the API as the
   model name, 400-ing against any real provider. The alias is a
   source-level handle; the concrete model always comes from OPENAI_MODEL.
   The comment said this was the intent — the condition was inverted.

2. The infer prompt never told the model what shape to return, so it
   guessed field names (returned {"summary": ...} for a type named Summary
   with a `text` field). Coercion then silently dropped the field.

   InferRequest now carries a compact type schema (rendered from the AST +
   TypeRegistry) and the prompt includes it: "Respond with only valid JSON
   matching this shape: { text: String }".

Verified end-to-end against real services:
  OPENAI_API_KEY=... OPENAI_BASE_URL=https://openrouter.ai/api/v1 \
    OPENAI_MODEL=openai/gpt-4o-mini GITHUB_TOKEN=... \
    actc run examples/summarize.act summarize \
      repo='{"owner":"evalops","name":"act"}' path='"README.md"'
  => {"ok":{"text":"Act is a pre-alpha programming language..."}}

  actc run examples/open_pr.act open_pr ... => {"ok":"#1"}
  (PR opened, then closed + branch deleted — full write path proven.)

clippy 0, fmt clean, 53 tests pass.
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