{"id":26418198,"url":"https://github.com/beamlit/template-deepresearch","last_synced_at":"2025-03-18T01:17:17.582Z","repository":{"id":278484765,"uuid":"935589863","full_name":"beamlit/template-deepresearch","owner":"beamlit","description":"A template implementation of a deep research agent using LangGraph and GPT-4. This agent performs comprehensive research on any given topic by:  Generating an initial research plan and outline, breaking down the topic into logical sections and performing targeted web searches using Tavily.","archived":false,"fork":false,"pushed_at":"2025-02-28T18:07:30.000Z","size":115,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-28T21:52:08.303Z","etag":null,"topics":["agent","deepresearch","langgraph","python"],"latest_commit_sha":null,"homepage":"https://blaxel.ai","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/beamlit.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-02-19T17:33:44.000Z","updated_at":"2025-02-28T18:07:33.000Z","dependencies_parsed_at":"2025-02-20T03:22:38.526Z","dependency_job_id":"5d50cea4-3783-4e37-acda-deee3433e998","html_url":"https://github.com/beamlit/template-deepresearch","commit_stats":null,"previous_names":["beamlit/template-deepresearch"],"tags_count":0,"template":true,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/beamlit%2Ftemplate-deepresearch","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/beamlit%2Ftemplate-deepresearch/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/beamlit%2Ftemplate-deepresearch/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/beamlit%2Ftemplate-deepresearch/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/beamlit","download_url":"https://codeload.github.com/beamlit/template-deepresearch/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244135883,"owners_count":20403798,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["agent","deepresearch","langgraph","python"],"created_at":"2025-03-18T01:17:17.004Z","updated_at":"2025-03-18T01:17:17.572Z","avatar_url":"https://github.com/beamlit.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Template DeepResearch\n\nA template implementation of a deep research agent using LangGraph and GPT-4. This agent performs comprehensive research on any given topic by:\n\n1. Generating an initial research plan and outline\n2. Breaking down the topic into logical sections\n3. Performing targeted web searches using Tavily for each section\n4. Writing detailed section content based on search results\n5. Compiling and refining the final report\n\nThe implementation uses LangGraph for orchestrating the research workflow, with parallel processing of sections for improved efficiency. It leverages GPT-4 for content generation and the Tavily search API for gathering relevant, up-to-date information from the web.\n\nKey features:\n\n- Automated research planning and execution\n- Parallel processing of research sections\n- Web search integration via Tavily\n- Structured report generation with citations\n- Configurable search depth and report formatting\n\nSpecial thanks to:\n\n- [MG](https://www.analyticsvidhya.com/blog/2025/02/build-your-own-deep-research-agent): Creating this agent and showing an amazing tutorial\n- [Langchain](https://github.com/langchain-ai/open_deep_research/tree/main): Creating an awesome implementation of DeepResearch with langgraph\n- [OpenAI](https://openai.com/index/introducing-deep-research/): Showing everyone this feature\n\n## Prerequisites\n\n- **Python:** 3.12 or later.\n- **[UV](https://github.com/astral-sh/uv):** An extremely fast Python package and project manager, written in Rust.\n- **[Blaxel CLI](https://docs.blaxel.ai/Get-started):** Ensure you have the Blaxel CLI installed. If not, install it globally:\n  ```bash\n  curl -fsSL https://raw.githubusercontent.com/beamlit/toolkit/main/install.sh | BINDIR=$HOME/.local/bin sh\n  ```\n- **Blaxel login:** Login to Blaxel platform\n  ```bash\n    bl login YOUR-WORKSPACE\n  ```\n\n## Installation\n\n- **Clone the repository and install the dependencies**:\n\n  ```bash\n  git clone https://github.com/beamlit/template-deepresearch.git\n  cd template-deepresearch\n  uv sync\n  ```\n\n- **Environment Variables:** Create a `.env` file with your configuration. You can begin by copying the sample file:\n\n  ```bash\n  cp .env-sample .env\n  ```\n\n  Then, update the following values with your own credentials:\n\n  - [Tavily Api Key](https://app.tavily.com/home): `TAVILY_API_KEY`\n  - [OpenAI api key](https://platform.openai.com/api-keys): `OPENAI_API_KEY`\n\n- **Blaxel apply:** register your integration connection / functions / models on blaxel.ai\n\n```bash\nbl apply -R -f .blaxel\n```\n\n## Running the Server Locally\n\nStart the development server with hot reloading using the Blaxel CLI command:\n\n```bash\nbl serve --hotrealod\n```\n\n_Note:_ This command starts the server and enables hot reload so that changes to the source code are automatically reflected.\n\n## Testing your agent\n\n```bash\nbl chat --local template-deepresearch\n```\n\n_Note:_ This command starts a chat interface. Example question: Do a report of annual revenu for the last 10 years of NVIDIA\n\nor\n\n```\nbl run agent template-deepresearch --local --data '{\"input\": \"Do a report of annual revenu for the last 10 years of NVIDIA\", \"report_plan_depth\": 20, \"recursion_limit\": 100 }'\n```\n\n## Deploying to Blaxel\n\nWhen you are ready to deploy your application, run:\n\n```bash\nbl deploy\n```\n\nThis command uses your code and the configuration files under the `.blaxel` directory to deploy your application.\n\n## Project Structure\n\n- **src/**\n  - `agent.py` - Configures the chat agent, streams HTTP responses, and integrates conversational context.\n  - `llmlogic.py` - Where the magic happens\n  - `prompts.py` - List of prompts given to agents\n  - `functions` - Functions to search the web with Tavily\n- **.blaxel/** - Contains configuration files for Blaxel functions and models.\n- **pyproject.toml** -UV package manager file.\n\n## License\n\nThis project is licensed under the MIT License. See the [LICENSE](LICENSE) file for more details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbeamlit%2Ftemplate-deepresearch","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbeamlit%2Ftemplate-deepresearch","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbeamlit%2Ftemplate-deepresearch/lists"}