User Tools

Site Tools


wiki:ai:lie-detector_application

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

wiki:ai:lie-detector_application [2025/06/17 17:02] – created mcarverwiki:ai:lie-detector_application [2025/06/18 13:29] (current) – [Order of Events (Request Processing Flow)] mcarver
Line 20: Line 20:
  
 ===== Order of Events (Request Processing Flow) ===== ===== Order of Events (Request Processing Flow) =====
-  - **User Submits Audio File**+1.  **User Submits Audio File**
     * User uploads a .wav file via the web interface (''/'' route, POST method).     * User uploads a .wav file via the web interface (''/'' route, POST method).
     * File is saved locally as ''temp.wav''.     * File is saved locally as ''temp.wav''.
      
-  - **Speech-to-Text Transcription**+2.  **Speech-to-Text Transcription**
     * Azure Speech SDK is configured using credentials from Azure Key Vault.     * Azure Speech SDK is configured using credentials from Azure Key Vault.
     * The file is transcribed using continuous speech recognition.     * The file is transcribed using continuous speech recognition.
Line 30: Line 30:
     * If the transcript is empty, an error is logged, and the user is notified.     * If the transcript is empty, an error is logged, and the user is notified.
      
-  - **Sentiment Analysis**+3.  **Sentiment Analysis**
     * The transcript is passed to Azure Language Service (Text Analytics API).     * The transcript is passed to Azure Language Service (Text Analytics API).
     * The API returns the sentiment (positive, neutral, or negative) and associated confidence scores.     * The API returns the sentiment (positive, neutral, or negative) and associated confidence scores.
     * A telemetry event is logged with the sentiment analysis results.     * A telemetry event is logged with the sentiment analysis results.
      
-  - **Lie Detection via GPT-4.1**+4.  **Lie Detection via GPT-4.1**
     * The transcript is sent to a deployed GPT-4.1 model via the Azure OpenAI API.     * The transcript is sent to a deployed GPT-4.1 model via the Azure OpenAI API.
     * A structured prompt instructs the model to determine whether the statement is truthful or deceptive.     * A structured prompt instructs the model to determine whether the statement is truthful or deceptive.
     * The response is parsed, logged, and returned to the front end.     * The response is parsed, logged, and returned to the front end.
      
-  - **Rendering the Result**+5.  **Rendering the Result**
     * The final HTML page displays:     * The final HTML page displays:
       - The transcribed statement       - The transcribed statement
wiki/ai/lie-detector_application.1750179758.txt.gz · Last modified: by mcarver