Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
NotificationsYou must be signed in to change notification settings

X-Zero-L/pydantic-ai-deep-research

Repository files navigation

A toy project reimplementingopen_deep_research withpydantic-ai. All code logic and prompts are from the original project - I'm just playing around and learning

⚠️ This is just for fun and learning! If you need something reliable, please use the original project.

Installation

This project usesuv as the package manager. Simply run:

uv sync

Quick Start

  1. You'll need these API keys:

    • Tavily API key (required for web search)
    • Choose at least one of these:
      • OpenAI API key (if using OpenAI as provider)
      • Anthropic API key (if using Anthropic as provider)
  2. Copy.env.example to.env, configure your settings:

# RequiredTAVILY_API_KEY=your-tavily-key# Choose your providers and fill corresponding API keysPLANNER_PROVIDER=openai# or anthropicWRITER_PROVIDER=anthropic# or openai# If using OpenAIOPENAI_API_KEY=sk-xxxOPENAI_BASE_URL=# optional, default is official API# If using AnthropicANTHROPIC_API_KEY=xxxANTHROPIC_BASE_URL=# optional# Optional settingsPLANNER_MODEL=o3-mini# model for planningWRITER_MODEL=claude-3.5-sonnet# model for writingNUMBER_OF_QUERIES=3# searches per sectionMAX_SEARCH_DEPTH=2# max research iterationsMAX_RETRIES=3# API call retriesREPORT_STRUCTURE=# custom report template
  1. Run it:
python cli.py"your topic"

Demo & Logs

Here's what happens when you run it:

CLI Demo

All operations are logged tologfire, where you can track the execution flow:

Logfire Console

The logs show:

  • Search queries generation
  • Web search operations
  • Section writing progress
  • Model API calls

Known Issues

Well... pretty much everything 😂

  • Quality is totally unpredictable
  • Error handling is minimal
  • Code is messy
  • Test coverage? What's that?

Credits

Huge thanks toopen_deep_research! This is just a learning exercise based on their amazing work.

License

MIT (do whatever you want, but don't blame me if it breaks 😉)

About

No description or website provided.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages


[8]ページ先頭

©2009-2025 Movatter.jp