Skip to main content
rohity0003
June 22, 2026
Question

AI user chatbot

  • June 22, 2026
  • 8 replies
  • 0 views

Hello,

I have built a chatbot in appian. I have two objects in my interface. First is a text box, which takes user question. And, the second is a button user clicks to send question to AI bot and get response.

Currently, when text box loses focus, a local variable called isProcessing is turned to true(So the user can be shown that processing is occurring). And, when the button-press returns with AI response, the isProcessing is turned to false, and the AI response is shown to user.

I want to have it so that when the text box loses focus, the local variable isProcessing is turned to true, as well as data being sent to AI bot. And, then when AI bot returns, the isProcessing is turned to false, and result shown.

Is this possible?

Thanks for your time.

8 replies

stefanhelzle0001
June 22, 2026

I think this should work using a!asyncVariable. This way, you can declare a local variable and make it evaluation react on entering text, or pushing the button.

Give it a try. It might need a bit of tinkering, but should work.

rohity0003
June 22, 2026

Hi Stefan, thanks for the idea.  Here is what I ran into:

I need two events to happen in following sequence:
step 1: isProcessing is marked as true (allowing user to see a processing indicator on screen).
step 2: AI skill is called (via processModel), which generates process variables that I am reading back into interface.

aSyncVariable solution: I can get aSyncvariable to run, when isProcessing is updated, but for the value of the variable, it does not like me to run a process.  Is there another way to run a process using aSyncVariable as trigger?

rohity0003
June 22, 2026

Here is the best solution I've come up with so far:

In User Input text box's saveInto Block:
1. update isProcessing
2. call processModel to call AI Skill (isSynchronous=false)
2a. In 'onSuccess' block, read processId into a local variable.

A separate sub-interface loads ( when isProcessing = true ).
This has a local variable processingDone that checks every 30 seconds (refreshVariable) to see if the process is done ( using a process report).
When processingDone = true, a link appears to 'Show Results'.
- When clicked, this reads in the data that was calculated by the (AI Skill) process.

shubhama926776
June 22, 2026

Yes possible. Use the text field's saveInto to set isProcessing = true and kick off the AI via a process model with a!startProcess.
Note: a saveInto allows only one smart service, so use a process model if you need multiple backend steps.

rohity0003
June 22, 2026

Hello Shubham,

If I put isProcessing=true and startProcess(calling AI Skill) in same saveInto block:

isProcessing will not show up as True until the startProcess is finished processing ( by the that time the processing is done).

I've found  that saveInto executes as a single block.  It does not update interface until the entire block is finished.

Thanks for your time.

June 23, 2026

Hi [mention:9ca8802553484a9e971195e3d49e4c2d:e9ed411860ed4f2ba0265705b8793d05] when building a custom chat in Appian we recommend using a!chatField in combination with a!callLanguageModel

Here is the documentation for a!chatField - https://docs.appian.com/suite/help/26.5/Chat_Component.html
Here is the documentation for a!callLanguageModel - https://docs.appian.com/suite/help/26.5/fnc_system_call_language_model.html 

These two functions will provide you the flexibility you need to build out custom chat interactions.

In 26.6 Appian will be releasing a!agentChatField + Chat Agents that can leverage existing design objects as tools to service your users.

If you have any questions please feel free to reach out

-Sam

rohity0003
June 24, 2026

Hi Sam,

Thanks for the reminder.  We had developed our chat components some months before the chatField feature was rolled out.  I think its time for us to transition.

Thanks again.