Skip to main content

specstream-haystack

Give your Haystack pipeline or agent any list from the live web. Search components hand a pipeline pages to read; SpecStream hands it the finished list. Ask in plain words – "dental clinics in Lisbon with online booking", "US startups that filed a $5M+ Form D this week" – and get back every matching row as a Document, each with the page it was read from. The list starts only within a price you set in code, and the model can't raise it.

pip install -U specstream-haystack
export SPECSTREAM_API_KEY=ss_live_...   # Agents & API in your SpecStream workspace

A free account comes with $10 of work to use within 30 days and needs no card: specstream.ai.

In a pipeline

from haystack_integrations.components.fetchers.specstream import SpecStreamListFetcher

fetcher = SpecStreamListFetcher(max_price_usd=3, max_results=25)
result = fetcher.run(request="Breweries in Portland, Oregon that host events, with their website")

for doc in result["documents"]:
    print(doc.meta["source_url"], doc.content)

Each Document is one row. content is the row as JSON. meta carries source_url (the page the row was read from), checked_at, list_id, list_link, position, request and fields (the row's columns as a dict).

run also returns list_id, status, list_link and a message when the list was still running. When the quoted price is above max_price_usd, or the request is too vague to price, nothing runs and SpecStreamError explains why.

As an agent tool

from haystack.components.agents import Agent
from haystack.components.generators.chat import OpenAIChatGenerator
from haystack.dataclasses import ChatMessage
from haystack_integrations.tools.specstream import SpecStreamListTool

agent = Agent(
    chat_generator=OpenAIChatGenerator(model="gpt-4o"),
    tools=[SpecStreamListTool(max_price_usd=5)],
)
result = agent.run(messages=[ChatMessage.from_user("Find open grants for urban beekeeping in the EU and list their deadlines.")])
print(result["last_message"].text)

The agent writes the request and picks how many rows. You decide what one list may cost.

Retries don't buy twice

The same request with the same limits, in the same hour, reaches the run it already started instead of starting another. A retried step never pays for the list twice.

MIT licensed. Source: Specstreamai/specstream-tools.

Metadata

Release files for specstream-haystack 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for specstream-haystack 0.1.1
File Size Uploaded
specstream_haystack-0.1.1.tar.gz 10.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for specstream-haystack 0.1.1
File Interpreter ABI Platform
specstream_haystack-0.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 21.4 kB

Release files / specstream_haystack-0.1.1.tar.gz

Download URL specstream_haystack-0.1.1.tar.gz
Size 10.2 kB
Tags Source
SHA-256 checksum
How to use checksums
79875d2594f8e78c9c1f4177db629838fcd7c05853aad2b9551b7de28dedfbbf
BLAKE2b-256 checksum
How to use checksums
d5c65c1cf81aff8c982baa5fda7763b5e33f1e28823c1c526664ca7989473549
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.15

Release files / specstream_haystack-0.1.1-py3-none-any.whl

Download URL specstream_haystack-0.1.1-py3-none-any.whl
Size 11.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
aa273f24c4ad467ea09ad8e3fa2195017c0c2a552a627f96ffa6029209fd35a4
BLAKE2b-256 checksum
How to use checksums
f363ecd00d4201da2a3f58b5eb1c7a724389fb7225c566e33d17c370d99cddef
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.15

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page