Skip to main content

LLM-to-LLM interview framework for evaluating conversational capabilities

Project description

llm-talk: LLM-to-LLM interview framework for exploring conversational behavior

PyPI Tests

This started as a quick way to evaluate a new AI provider — and turned into something more interesting. Turns out LLMs have distinct interviewing personalities, struggle with conversational closure, and tend to converge on the same philosophical territory regardless of who's asking.

Full write-up, with example interview transcripts: When LLMs Interview Each Other

Quick Start

from llm_talk import Interview

result = Interview("openai", "claude").run()
result.save("output.md")
print(result.evaluation)

Installation

pip install llm-talk

Set your API keys as environment variables:

export OPENAI_API_KEY=sk-...
export ANTHROPIC_API_KEY=sk-ant-...

Usage

Model Aliases

Use short names or full provider:model strings:

Alias Resolves to
openai openai:gpt-4o-mini
claude anthropic:claude-sonnet-4-5
gpt4 openai:gpt-4o
sonnet anthropic:claude-sonnet-4-5
opus anthropic:claude-opus-4-5
gemini google:gemini-2.0-flash
mistral mistral:mistral-large-latest
Interview("openai:gpt-4o", "anthropic:claude-opus-4-5").run()

Custom Topics

result = Interview(
    "openai", "claude",
    topics="Test their reasoning and code generation capabilities"
).run(turns=30)

Topic Templates

from llm_talk import Interview, TopicTemplate

result = Interview("openai", "claude", topics=TopicTemplate.TECHNICAL).run()

Available templates: DEFAULT, TECHNICAL, CREATIVE, CULTURAL.

Control Turn Count

result = Interview("openai", "claude").run(turns=100)

Custom Evaluator

By default, Claude evaluates the conversation. You can change the evaluator model, dimensions, or prompt:

from llm_talk import Interview, EvaluatorTemplate

# Use a different model as evaluator
result = Interview("claude", "openai", evaluator="gpt4").run()

# Focus evaluation on specific dimensions
result = Interview(
    "claude", "openai",
    evaluation_dimensions=EvaluatorTemplate.TECHNICAL_DIMENSIONS,
).run()

# Override the evaluator system prompt
result = Interview(
    "openai", "claude",
    evaluator_system_prompt="You are a terse, skeptical reviewer. One paragraph per section. No flattery.",
).run()

# Fully custom evaluator prompt
result = Interview(
    "openai", "claude",
    evaluator_user_prompt="Score the interviewee on depth, honesty, and clarity (1-10 each). Reply with a markdown table.",
).run()

Access Results

result = Interview("openai", "claude").run()

print(result.evaluation)        # Claude's evaluation
print(result.total_turns)       # Actual turns completed
print(result.loop_detected)     # Was a loop detected?
print(result.loop_reason)       # Why the loop was detected

result.save("interview.md")     # Save as markdown
data = result.to_dict()         # Export as dict (for JSON)

How It Works

  1. Two LLM agents are created — one as interviewer, one as interviewee
  2. They have a natural conversation for the specified number of turns
  3. Loop detection monitors for repetitive patterns (farewell loops, etc.)
  4. Claude evaluates the conversation quality and generates a report
  5. Results include the full conversation, evaluation, and metadata

Examples

See the examples/ directory for more usage patterns:

Development

git clone https://github.com/am1t/llm-talk.git
cd llm-talk
pip install -e ".[dev]"
pytest

To run the example scripts, also install the examples extra:

pip install -e ".[examples]"

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

llm_talk-0.2.1.tar.gz (134.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

llm_talk-0.2.1-py3-none-any.whl (15.7 kB view details)

Uploaded Python 3

File details

Details for the file llm_talk-0.2.1.tar.gz.

File metadata

  • Download URL: llm_talk-0.2.1.tar.gz
  • Upload date:
  • Size: 134.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.2

File hashes

Hashes for llm_talk-0.2.1.tar.gz
Algorithm Hash digest
SHA256 4be0a128c1ee0e413de4f93784e9317910a01e2acbca3634939a27848c1edc86
MD5 144f051d5accb63875a49d6bf9ebfa98
BLAKE2b-256 4c3a21a36fa63b938d312282cab8d96423d87332d2c90ad7df0a506ef466c07c

See more details on using hashes here.

File details

Details for the file llm_talk-0.2.1-py3-none-any.whl.

File metadata

  • Download URL: llm_talk-0.2.1-py3-none-any.whl
  • Upload date:
  • Size: 15.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.2

File hashes

Hashes for llm_talk-0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 4c01a0faa2a7d38ac071042f69f96434b288b9586ba1cedfcf29bc620f4dea29
MD5 8ab24328db521afbb0f1987c08090424
BLAKE2b-256 15389d45b4cff0df6860fb7fd29e2390bee1dcfa59d9054984f8c28acf0fd4a5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page