fix: Expose Required params to Anthropic API (#752)
* chore: add build task and generates annotations
Added a build task for parity with other task commands.
Used the suggested build command from the README.
Also added "generates" annotations, which is useful as the
Taskfile grows.
Signed-off-by: Evan Wies <evan@neomantra.net>
* fix: expose Required params to Anthropic client
Signed-off-by: Evan Wies <evan@neomantra.net>
* fix: typo in cla.yml precomment -> prcomment
Signed-off-by: Evan Wies <evan@neomantra.net>
---------
Signed-off-by: Evan Wies <evan@neomantra.net>
commita02bd99a2d89e36f75b5afc2d1d0d68b71912427
authorEvan <evan@neomantra.net>
dateMon 18 Aug 2025, 14:10 (1 year ago)
parent2437feb
.github/workflows/cla.yml+1−1
@@ -31,6 +31,6 @@ jobs:
3131 branch: "main"
3232 allowlist: charmcli,charmcrush,dependabot[bot]
3333 custom-pr-sign-comment: "I have read the Contributor License Agreement (CLA) and hereby sign the CLA."
34− custom-notsigned-precomment: "Thank you for your submission. We really appreciate it! Like many open-source projects, we ask that you sign our [Contributor License Agreement](https://github.com/charmbracelet/crush/blob/main/CLA.md) before we can accept your contribution. You can sign the CLA by just posting a Pull Request comment same as the below format."
34+ custom-notsigned-prcomment: "Thank you for your submission. We really appreciate it! Like many open-source projects, we ask that you sign our [Contributor License Agreement](https://github.com/charmbracelet/crush/blob/main/CLA.md) before we can accept your contribution. You can sign the CLA by just posting a Pull Request comment same as the below format."
3535 lock-pullrequest-aftermerge: false
3636 signed-commit-message: "chore(legal): @$contributorName has signed the CLA"
Taskfile.yaml+9
@@ -28,6 +28,13 @@ tasks:
2828 env:
2929 GOEXPERIMENT: null
3030
31+ build:
32+ desc: Run build
33+ cmds:
34+ - go build .
35+ generates:
36+ - crush
37+
3138 test:
3239 desc: Run tests
3340 cmds:
@@ -70,3 +77,5 @@ tasks:
7077 cmds:
7178 - go run main.go schema > schema.json
7279 - echo "Generated schema.json"
80+ generates:
81+ - schema.json
internal/llm/provider/anthropic.go+1−1
@@ -178,7 +178,7 @@ func (a *anthropicClient) convertTools(tools []tools.BaseTool) []anthropic.ToolU
178178 Description: anthropic.String(info.Description),
179179 InputSchema: anthropic.ToolInputSchemaParam{
180180 Properties: info.Parameters,
181− // TODO: figure out how we can tell claude the required fields?
181+ Required: info.Required,
182182 },
183183 }
184184