Skip to content

Update examples#187

Open
anbuzin wants to merge 11 commits into
mainfrom
update-examples
Open

Update examples#187
anbuzin wants to merge 11 commits into
mainfrom
update-examples

Conversation

@anbuzin

@anbuzin anbuzin commented Jun 26, 2026

Copy link
Copy Markdown
Collaborator

Restructures examples and adds a couple new ones that seem sensible. The new layout mirrors the framework API, example apps are now all end-to-end agents with web (useChat), Slack, and Textual UI.

Details
  examples/
  ├── README.md
  ├── agents/                      # agent loops, tools, hooks
  │   ├── basic.py                 # model + tool, default loop
  │   ├── content_tool.py          # tool returning images the model can see
  │   ├── custom_hook.py           # pause a tool for external input
  │   ├── custom_loop.py           # hand-rolled stream + ToolRunner loop
  │   ├── mcp_tools.py             # MCP (Context7) tools
  │   ├── streaming_tool.py        # async-generator tool, streamed progress
  │   ├── subagent.py              # nested agent as a tool
  │   └── tool_approval.py         # require_approval: live + interrupted replay
  ├── models/                      # model layer: streaming, output, providers
  │   ├── stream.py
  │   ├── structured_output.py
  │   ├── prompt_caching.py
  │   ├── check_connection.py      # credential / model availability check
  │   ├── anthropic/               # stream, builtin web search
  │   ├── gateway/                 # stream, builtin web search, model params
  │   └── openai/                  # stream, chat completions, explicit client
  ├── media/                       # image/video generation, multimodal input
  │   ├── image_generation.py
  │   ├── image_edit.py
  │   ├── inline_image.py
  │   ├── multimodal_input.py
  │   └── video_generation.py
  └── apps/                        # end-to-end demos
      ├── coding_agent/            # one-file Textual TUI, bash tool + approvals
      ├── slack_agent/             # one-file Socket Mode bot, streams to threads
      ├── web_agent/               # FastAPI + React (AI SDK UI), HITL approval
      ├── durable_agent_temporal/  # agent turn as Temporal workflow + activities
      └── durable_agent_workflows/ # same agent on Vercel Workflows

@vercel

vercel Bot commented Jun 26, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
ai-python Ready Ready Preview, Comment Jul 4, 2026 12:09am

@anbuzin anbuzin force-pushed the update-examples branch from 11a6a01 to 2b79411 Compare July 4, 2026 00:07
@anbuzin anbuzin marked this pull request as ready for review July 4, 2026 00:07
@anbuzin anbuzin requested a review from msullivan July 4, 2026 00:08
E2E_TESTS = [
Sample(
"multiagent-textual/test-e2e.py",
"apps/multiagent-textual/test-e2e.py",

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The E2E_TESTS list in run-examples.py references example paths that no longer exist after the PR's reorganization, so --e2e/--all runs will fail to find the files.

Fix on Vercel

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