• bitcoinBitcoin(BTC)$85,644.00-0.65%
  • ethereumEthereum(ETH)$2,711.81-1.63%
  • tetherTether(USDT)$1.000.00%
  • binancecoinBNB(BNB)$780.39-1.24%
  • rippleXRP(XRP)$1.57-0.98%
  • usd-coinUSDC(USDC)$1.000.01%
  • solanaSolana(SOL)$116.60-0.96%
  • tronTRON(TRX)$0.341670-0.44%
  • zcashZcash(ZEC)$1,631.987.56%
  • Figure HelocFigure Heloc(FIGR_HELOC)$1.031.76%
  • HyperliquidHyperliquid(HYPE)$95.410.00%
  • dogecoinDogecoin(DOGE)$0.099259-1.64%
  • moneroMonero(XMR)$564.26-1.59%
  • whitebitWhiteBIT Coin(WBT)$85.89-1.00%
  • USDSUSDS(USDS)$1.000.00%
  • chainlinkChainlink(LINK)$12.68-3.07%
  • cardanoCardano(ADA)$0.248094-2.01%
  • RainRain(RAIN)$0.012676-5.92%
  • leo-tokenLEO Token(LEO)$8.980.11%
  • stellarStellar(XLM)$0.212307-1.69%
  • bitcoin-cashBitcoin Cash(BCH)$353.118.08%
  • nearNEAR Protocol(NEAR)$4.736.45%
  • uniswapUniswap(UNI)$9.525.19%
  • Ethena USDeEthena USDe(USDE)$1.000.01%
  • litecoinLitecoin(LTC)$62.600.85%
  • avalanche-2Avalanche(AVAX)$10.75-2.39%
  • daiDai(DAI)$1.000.00%
  • CantonCanton(CC)$0.111667-4.78%
  • USD1USD1(USD1)$1.00-0.01%
  • suiSui(SUI)$1.01-1.17%
  • hedera-hashgraphHedera(HBAR)$0.093958-3.06%
  • the-open-networkGram (prev. Toncoin)(GRAM)$1.440.45%
  • BittensorBittensor(TAO)$310.87-2.92%
  • shiba-inuShiba Inu(SHIB)$0.000006-1.25%
  • Global DollarGlobal Dollar(USDG)$1.000.00%
  • crypto-com-chainCronos(CRO)$0.065196-2.44%
  • MemeCoreMemeCore(M)$1.25-5.12%
  • paypal-usdPayPal USD(PYUSD)$1.000.00%
  • tether-goldTether Gold(XAUT)$4,286.08-1.17%
  • BitwayBitway(BTW)$0.9612.17%
  • okbOKB(OKB)$121.16-1.06%
  • Circle USYCCircle USYC(USYC)$1.140.01%
  • Ripple USDRipple USD(RLUSD)$1.00-0.02%
  • BlackRock USD Institutional Digital Liquidity FundBlackRock USD Institutional Digital Liquidity Fund(BUIDL)$1.000.00%
  • Ondo US Dollar YieldOndo US Dollar Yield(USDY)$1.150.23%
  • aaveAave(AAVE)$145.820.99%
  • mantleMantle(MNT)$0.670.63%
  • EthenaEthena(ENA)$0.210603-0.10%
  • OndoOndo(ONDO)$0.429917-0.98%
  • pepePepe(PEPE)$0.000005-4.66%
TradePoint.io
  • Main
  • AI & Technology
  • Stock Charts
  • Market & News
  • Business
  • Finance Tips
  • Trade Tube
  • Blog
  • Shop
No Result
View All Result
TradePoint.io
No Result
View All Result

How to Create Reliable Conversational AI Agents Using Parlant?

September 23, 2025
in AI & Technology
Reading Time: 7 mins read
A A
How to Create Reliable Conversational AI Agents Using Parlant?
ShareShareShareShareShare

Parlant is a framework designed to help developers build production-ready AI agents that behave consistently and reliably. A common challenge when deploying large language model (LLM) agents is that they often perform well in testing but fail when interacting with real users. They may ignore carefully designed system prompts, generate inaccurate or irrelevant responses at critical moments, struggle with edge cases, or produce inconsistent behavior from one conversation to another. 

Parlant addresses these challenges by shifting the focus from prompt engineering to principle-driven development. Instead of relying on prompts alone, it provides mechanisms to define clear rules and tool integrations, ensuring that an agent can access and process real-world data safely and predictably.

YOU MAY ALSO LIKE

Apple Links Landmarks On Its Maps App To Hidden Histories Podcast Episodes

Nokia Open-Sources AnyJev: A Training-Free Layer That Turns Any Open LLM Into a Calibrated Decision Model

In this tutorial, we will create an insurance agent that can retrieve open claims, file new claims, and provide detailed policy information, demonstrating how to integrate domain-specific tools into a Parlant-powered AI system for consistent and reliable customer support. Check out the FULL CODES here. 

Installing & importing the dependencies

import asyncio
from datetime import datetime
import parlant.sdk as p

Defining the tools

The following code block introduces three tools that simulate interactions an insurance assistant might need. 

  • The get_open_claims tool represents an asynchronous function that retrieves a list of open insurance claims, allowing the agent to provide users with up-to-date information about pending or approved claims. 
  • The file_claim tool accepts claim details as input and simulates the process of filing a new insurance claim, returning a confirmation message to the user. 

Finally, the get_policy_details tool provides essential policy information, such as the policy number and coverage limits, enabling the agent to respond accurately to questions about insurance coverage. Check out the FULL CODES here. 

@p.tool
async def get_open_claims(context: p.ToolContext) -> p.ToolResult:
    return p.ToolResult(data=["Claim #123 - Pending", "Claim #456 - Approved"])
@p.tool
async def file_claim(context: p.ToolContext, claim_details: str) -> p.ToolResult:
    return p.ToolResult(data=f"New claim filed: {claim_details}")
@p.tool
async def get_policy_details(context: p.ToolContext) -> p.ToolResult:
    return p.ToolResult(data={
        "policy_number": "POL-7788",
        "coverage": "Covers accidental damage and theft up to $50,000"
    })

Defining Glossary & Journeys

In this section, we define the glossary and journeys that shape how the agent handles domain knowledge and conversations. The glossary contains important business terms, such as the customer service number and operating hours, allowing the agent to reference them accurately when needed. 

The journeys describe step-by-step processes for specific tasks. In this example, one journey walks a customer through filing a new insurance claim, while another focuses on retrieving and explaining policy coverage details. Check out the FULL CODES here. 

async def add_domain_glossary(agent: p.Agent):
    await agent.create_term(
        name="Customer Service Number",
        description="You can reach us at +1-555-INSURE",
    )
    await agent.create_term(
        name="Operating Hours",
        description="We are available Mon-Fri, 9AM-6PM",
    )
async def create_claim_journey(agent: p.Agent) -> p.Journey:
    journey = await agent.create_journey(
        title="File an Insurance Claim",
        description="Helps customers report and submit a new claim.",
        conditions=["The customer wants to file a claim"],
    )
    s0 = await journey.initial_state.transition_to(chat_state="Ask for accident details")
    s1 = await s0.target.transition_to(tool_state=file_claim, condition="Customer provides details")
    s2 = await s1.target.transition_to(chat_state="Confirm claim was submitted")
    await s2.target.transition_to(state=p.END_JOURNEY)
    return journey
async def create_policy_journey(agent: p.Agent) -> p.Journey:
    journey = await agent.create_journey(
        title="Explain Policy Coverage",
        description="Retrieves and explains customer's insurance coverage.",
        conditions=["The customer asks about their policy"],
    )
    s0 = await journey.initial_state.transition_to(tool_state=get_policy_details)
    await s0.target.transition_to(
        chat_state="Explain the policy coverage clearly",
        condition="Policy info is available",
    )
    await agent.create_guideline(
        condition="Customer presses for legal interpretation of coverage",
        action="Politely explain that legal advice cannot be provided",
    )
    return journey

The main runner ties together all the components defined in earlier cells and launches the agent. It starts a Parlant server, creates the insurance support agent, and loads its glossary, journeys, and global guidelines. It also handles edge cases such as ambiguous customer intent by prompting the agent to choose between relevant journeys. Finally, once the script is executed, the server becomes active and prints a confirmation message. You can then open your browser and navigate to http://localhost:8800 to access the Parlant UI and begin interacting with the insurance agent in real time. Check out the FULL CODES here. 

async def main():
    async with p.Server() as server:
        agent = await server.create_agent(
            name="Insurance Support Agent",
            description="Friendly and professional; helps with claims and policy queries.",
        )
        await add_domain_glossary(agent)
        claim_journey = await create_claim_journey(agent)
        policy_journey = await create_policy_journey(agent)
        # Disambiguation: if intent is unclear
        status_obs = await agent.create_observation(
            "Customer mentions an issue but doesn't specify if it's a claim or policy"
        )
        await status_obs.disambiguate([claim_journey, policy_journey])
        # Global guideline
        await agent.create_guideline(
            condition="Customer asks about unrelated topics",
            action="Kindly redirect them to insurance-related support only",
        )
        print("✅ Insurance Agent is ready! Open the Parlant UI to chat.")
if __name__ == "__main__":
    import asyncio
    asyncio.run(main())

Check out the FULL CODES here. Feel free to check out our GitHub Page for Tutorials, Codes and Notebooks. Also, feel free to follow us on Twitter and don’t forget to join our 100k+ ML SubReddit and Subscribe to our Newsletter.

For content partnership with marktechpost.com, please TALK to us


I am a Civil Engineering Graduate (2022) from Jamia Millia Islamia, New Delhi, and I have a keen interest in Data Science, especially Neural Networks and their application in various areas.

🔥[Recommended Read] NVIDIA AI Open-Sources ViPE (Video Pose Engine): A Powerful and Versatile 3D Video Annotation Tool for Spatial AI

Credit: Source link

ShareTweetSendSharePin

Related Posts

Apple Links Landmarks On Its Maps App To Hidden Histories Podcast Episodes
AI & Technology

Apple Links Landmarks On Its Maps App To Hidden Histories Podcast Episodes

September 23, 2026
Nokia Open-Sources AnyJev: A Training-Free Layer That Turns Any Open LLM Into a Calibrated Decision Model
AI & Technology

Nokia Open-Sources AnyJev: A Training-Free Layer That Turns Any Open LLM Into a Calibrated Decision Model

September 23, 2026
Kyutai Releases Voice of Reason: A Speech-Native Model that Solves Spoken Math with Reinforcement Learning
AI & Technology

Kyutai Releases Voice of Reason: A Speech-Native Model that Solves Spoken Math with Reinforcement Learning

September 23, 2026
OpenAI Releases GPT-6 Sol and Luna: 50% Cheaper API Pricing and Benchmarks
AI & Technology

OpenAI Releases GPT-6 Sol and Luna: 50% Cheaper API Pricing and Benchmarks

September 23, 2026
Next Post
My Wife Doesn’t Want Me To Spend ,000 A Year On A Sailboat

My Wife Doesn't Want Me To Spend $6,000 A Year On A Sailboat

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Search

No Result
View All Result
Nunchux AI Introduces VC-Attention: A Training-Free Low-Bit Attention Kernel That Speeds Up Video Diffusion Transformers

Nunchux AI Introduces VC-Attention: A Training-Free Low-Bit Attention Kernel That Speeds Up Video Diffusion Transformers

September 17, 2026
May World Oil Production At Post-War Low

May World Oil Production At Post-War Low

September 16, 2026
Knowledgator Releases GLiFormer: A 575M-Parameter Encoder That Hits 91.10 F1 on Nested JSON Extraction Without Generating Tokens

Knowledgator Releases GLiFormer: A 575M-Parameter Encoder That Hits 91.10 F1 on Nested JSON Extraction Without Generating Tokens

September 16, 2026

About

Learn more

Our Services

Legal

Privacy Policy

Terms of Use

Bloggers

Learn more

Article Links

Contact

Advertise

Ask us anything

©2020- TradePoint.io - All rights reserved!

Tradepoint.io, being just a publishing and technology platform, is not a registered broker-dealer or investment adviser. So we do not provide investment advice. Rather, brokerage services are provided to clients of Tradepoint.io by independent SEC-registered broker-dealers and members of FINRA/SIPC. Every form of investing carries some risk and past performance is not a guarantee of future results. “Tradepoint.io“, “Instant Investing” and “My Trading Tools” are registered trademarks of Apperbuild, LLC.

This website is operated by Apperbuild, LLC. We have no link to any brokerage firm and we do not provide investment advice. Every information and resource we provide is solely for the education of our readers. © 2020 Apperbuild, LLC. All rights reserved.

No Result
View All Result
  • Main
  • AI & Technology
  • Stock Charts
  • Market & News
  • Business
  • Finance Tips
  • Trade Tube
  • Blog
  • Shop

© 2023 - TradePoint.io - All Rights Reserved!