Skip to content

Add Parallel Search + Cartesia Line integration#1

Open
georgeatparallel wants to merge 15 commits into
mainfrom
george/parallel-cartesia-line
Open

Add Parallel Search + Cartesia Line integration#1
georgeatparallel wants to merge 15 commits into
mainfrom
george/parallel-cartesia-line

Conversation

@georgeatparallel

@georgeatparallel georgeatparallel commented Jun 30, 2026

Copy link
Copy Markdown
Owner

Summary

This is a fork-only review PR before opening anything upstream.

It adds a Cartesia community integration page for Parallel Search + Cartesia Line. The example builds a Line agent with a web_search loopback tool and calls Parallel Search with mode="turbo" through the Parallel Python SDK.

Latest updates

I tightened the guide to match Cartesia's community-integration style: the quick start is step-by-step, the voice agent avoids reading citations or URLs aloud, and the example stays focused on the smallest runnable Line agent.

I also sharpened the example around the intended product message: Turbo Search inside a live voice turn. The guide calls out mode="turbo" as Parallel's lowest-latency Search mode, uses a neutral time-sensitive weather prompt, and now defaults to 3 results x 240 excerpt chars = 720 total chars with LINE_MAX_TOKENS=180 so the docs match the lower-latency demo path.

After testing the real Cartesia voice path, I added current-date prompt guidance and then moved that prompt into a per-agent system_prompt() helper so new calls get a fresh date. The agent includes date/year context for relative-time searches and tells the model to say when results are stale or conflicting instead of guessing.

Checked

  • Extracted the embedded Python and compiled/imported it with cartesia-line + parallel-web
  • Confirmed the documented defaults resolve to MAX_RESULTS=3, MAX_EXCERPT_CHARS=240, MAX_CHARS_TOTAL=720, and LINE_MAX_TOKENS=180
  • Constructed the Cartesia LlmAgent from the extracted code and confirmed the Cerebras config path keeps reasoning_effort="low"
  • Ran a live Parallel Search call with mode="turbo" and the documented defaults; it returned 3 results and formatted a voice payload successfully
  • Ran the extracted docs code as a temporary Line server and checked GET /status plus Cartesia-shaped POST /chats
  • Scanned the submission for stale old-default text and ran git diff --check

Note

This PR targets my fork only. It is not opened against cartesia-ai/community-integrations.

@georgeatparallel
georgeatparallel marked this pull request as ready for review June 30, 2026 23:25
@georgeatparallel
georgeatparallel force-pushed the george/parallel-cartesia-line branch from a767409 to 2d0248d Compare June 30, 2026 23:28
@georgeatparallel
georgeatparallel marked this pull request as draft June 30, 2026 23:28
@georgeatparallel
georgeatparallel marked this pull request as ready for review June 30, 2026 23:32
Comment thread submissions/parallel-cartesia-line.mdx Outdated
Comment thread submissions/parallel-cartesia-line.mdx Outdated
| Parameter | Type | Default | Description |
| --- | --- | --- | --- |
| `PARALLEL_MAX_RESULTS` | `int` | `3` | Maximum number of search results returned to the LLM. |
| `PARALLEL_MAX_CHARS_TOTAL` | `int` | `1800` | Character budget for search excerpts across all results. |

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

are these sensible defaults?

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

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

seems decent - maybe not enough results? I was thinking speed first. wdyt? 5? 8?

Comment thread submissions/parallel-cartesia-line.mdx Outdated
Comment thread submissions/parallel-cartesia-line.mdx Outdated
return []

body = {
"objective": (

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

might be a redudant objective, you can just user search queries

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

not sure if you want to somehow customize for voice agents in particular

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

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

agreed. for this search_queries=[query] is enough and keeps the SDK call easier to copy. I removed the custom objective and left voice response behavior to the agent prompt.

@georgeatparallel
georgeatparallel force-pushed the george/parallel-cartesia-line branch from 2d0248d to fee76dd Compare June 30, 2026 23:56
@georgeatparallel
georgeatparallel marked this pull request as draft June 30, 2026 23:57
@georgeatparallel
georgeatparallel marked this pull request as ready for review July 1, 2026 00:02
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.

3 participants