AI chat
tomba chat takes requests in plain language, such as "Find the head of sales at Stripe and verify their email", and lets an OpenAI model decide which Tomba lookups to run. It uses your own OpenAI API key.
Requirements
- The CLI, signed in to Tomba (Authentication).
- An OpenAI API key in the
OPENAI_API_KEYenvironment variable. OpenAI bills its usage to that key.
Data and credits
The CLI sends your messages, its instructions to the model, the list of available lookups, and the full response of every lookup it runs to OpenAI's Chat Completions API (https://api.openai.com/v1/chat/completions), from your machine and with your key. In batch mode, it also sends values from each CSV row.
Lookup results sent to OpenAI include personal data, such as people's names, email addresses, and phone numbers.
The model chooses the lookups, and one request can lead to several of them. Each is a Tomba API request billed as described in Credit costs, and the CLI doesn't ask before running it.
An interactive chat saves nothing locally: the conversation is kept in memory until you exit. Batch mode writes one CSV file.
Start a chat
Code
Type a request at the You: prompt. The CLI prints the lookups the model ran, such as workflow: domain_search -> email_finder -> email_verifier, followed by the model's answer. Type quit, exit, or q to leave.
| Flag | Type | Default | Description |
|---|---|---|---|
--model | string | gpt-4o | OpenAI model to use. It must support tool calling. |
--file | string | — | CSV file to process in batch mode. |
--type | string | enrich | Batch operation: enrich, verify, finder, or search. |
--output, -o | string | <input>_enriched.csv | Output file in batch mode. |
The help for --type also lists linkedin and author, but the CLI builds no request for those types, so their rows fail.
Lookups the model can run
| Tool | Calls |
|---|---|
domain_search | GET /v1/domain-search |
email_finder | GET /v1/email-finder |
email_verifier | GET /v1/email-verifier |
email_enrichment | GET /v1/enrich |
email_count | GET /v1/email-count |
email_sources | GET /v1/email-sources |
linkedin_finder | GET /v1/linkedin |
author_finder | GET /v1/author-finder |
domain_status | GET /v1/domain-status |
phone_finder | GET /v1/phone-finder |
Batch mode
Code
For each row, the CLI sends the model one request built from the row:
--type | Request sent for each row |
|---|---|
enrich, verify | The value of the column named email, e-mail, mail, or email_address; without one, the whole row |
search | The value of the column named domain, company_domain, or website; without one, the whole row |
finder | Every non-empty column, as column=value pairs |
Rows are processed one at a time. When all rows are done, the CLI writes the output file, with your input columns followed by the same result columns as tomba bulk, and prints a table of the first 20 rows. It doesn't resume an interrupted run. The input must be a comma-separated file with a header row, and every row must have the same number of fields.
To run a single lookup per row without OpenAI, use tomba bulk.
Examples
Code