🎉 I just released my first Python package, guided-capture, a cool new Python package that automates structured interviews using AI in order to gather the right context for your AI applications.
A ton of AI features are limited by the knowledge in the minds of the end users and the application’s ability to extract and use that knowledge. Whether your app is doing design work, conducting research, or simply trying to automate the user’s request, the AI feature or agent will often struggle to perform at a high levelwithout the right context.
That’s why I made guided-capture; in order to gather the right context for your AI use-cases.
guided-capture
uses LLMs to help you conduct structured, goal-oriented interviews with users. It automatically generates relevant questions based on your objectives and neatly synthesizes responses into your desired output format. I think the best part is that it’s completely UI-agnostic, meaning you can integrate it into any interface—CLI, web, mobile, you name it. And you can capture the answers in text, voice, or even a mix of both.
Installation is straightforward:
pip install guided-capture
Here’s how easy it is to get started:
from openai import OpenAI
from guided_capture import GuidedCapture
client = OpenAI(api_key="your-api-key")
capture = GuidedCapture(
topic="Company Vision",
output_format_description="A concise company mission statement",
llm_client=client
)
questions = capture.get_questions()
# Just a sample way to snag user input. You can plug in any UI for answer capture.
for question in questions:
print(f"\n{question}")
answer = input("Your answer: ")
capture.submit_answer(question, answer)
result = capture.process_answers()
print("\nFinal Output:", result)
guided-capture’s UI-agnostic design means you can:
Give it a try, submit a PR, and let me know if it’s useful for your app. Happy hacking!
- Joseph
P.S. The library is so simple that you don’t really have to even use it, just ask AI to implmenent something similar. I just think it’s a powerful paradigm that unlocks a bunch of new apps.
Sign up for my email list to know when I post more content like this. I also post my thoughts on Twitter/X.