Skip to content

fix(go-agent): Yahoofinance input and run - #16658

Merged
JinHai-CN merged 1 commit into
infiniflow:mainfrom
Harry-Hz-Zhang:fix/agent-YahooFinance
Jul 6, 2026
Merged

JinHai-CN merged 1 commit into
infiniflow:mainfrom
Harry-Hz-Zhang:fix/agent-YahooFinance

Conversation

@Harry-Hz-Zhang

Copy link
Copy Markdown
Contributor

Summary

Debugging YahooFinance component in agent canvas returns "unknown component" and "no input_form".
YahooFinance was only registered as an eino tool, not as a runtime component. The component factory only searches the runtime registry.

  • universe_a_wrappers.go: add yahooFinanceComponent wrapper delegating to agenttool.YahooFinanceTool with GetInputForm()
  • fixture_stubs.go: register "YahooFinance" component

TEST

go build and go test ./internal/agent/component/... all pass.

@dosubot dosubot Bot added the size:M This PR changes 30-99 lines, ignoring generated files. label Jul 6, 2026
@Harry-Hz-Zhang Harry-Hz-Zhang added 🐞 bug Something isn't working, pull request that fix bug. ci Continue Integration labels Jul 6, 2026
@coderabbitai

coderabbitai Bot commented Jul 6, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 9bc2d935-6d50-4c5b-a25f-696c8eb604ce

📥 Commits

Reviewing files that changed from the base of the PR and between 98189cd and f545215.

📒 Files selected for processing (2)
  • internal/agent/component/fixture_stubs.go
  • internal/agent/component/universe_a_wrappers.go

📝 Walkthrough

Walkthrough

Adds a new yahooFinanceComponent canvas wrapper that delegates to agenttool.YahooFinanceTool, implementing standard Component interface methods with input validation, tool invocation, and error handling. Registers the new component under the name "YahooFinance" in the component fixture registry.

Changes

YahooFinance Component Addition

Layer / File(s) Summary
Wrapper implementation and interface checks
internal/agent/component/universe_a_wrappers.go
Adds yahooFinanceComponent wrapping agenttool.YahooFinanceTool with Name, Inputs, Outputs, Invoke (validates stock_code, invokes tool, handles errors), GetInputForm, and non-streaming Stream; extends compile-time assertions for Component and InvokableTool interfaces.
Registry wiring
internal/agent/component/fixture_stubs.go
Registers "YahooFinance" name mapped to newYahooFinanceComponent in init().

Estimated code review effort: 2 (Simple) | ~10 minutes

Poem

A rabbit hops through market news today,
With YahooFinance now paving the way. 🐇📈
Stock codes checked, no blanks allowed,
Reports return, clear and proud.
Hop, hop — another tool wired in!

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title is concise and clearly reflects the YahooFinance component fix in the PR.
Description check ✅ Passed The description includes the required Summary section plus useful background and test validation.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@JinHai-CN
JinHai-CN merged commit b2e82a4 into infiniflow:main Jul 6, 2026
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🐞 bug Something isn't working, pull request that fix bug. ci Continue Integration size:M This PR changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants