I Tried to Build a Lie Detector with SmartSpectra. Here's What I Built Instead.
This is a submission for the Presage SmartSpectra SDK Challenge.
What I Built
My first idea was a lie detector: point a camera at someone, ask questions, watch their vital signs, and catch the lie. The more I read, the less that idea held up.
Pulse, breathing and expressions change when someone is nervous, tired, excited or just sitting differently. They don't change because someone is lying. Real polygraphs have the same problem, which is why nervous truth-tellers fail them. A "lie score" built on these signals would look scientific and would be wrong in ways that could hurt people.
So I built Signal Session, a consent-first conversation workspace that does the opposite of a lie detector. It shows a live signal openly, to both people, and says plainly what that signal can't tell you.
With Signal Session you can:
- Prepare a conversation. Write neutral, open-ended questions and add image or video prompts, then step through them one at a time.
- See a live breathing-rate estimate from SmartSpectra, with the SDK's confidence and stability, and a short trend line.
- Take private notes that stay on your own computer.
- Stay in control. The participant gives consent themselves before the camera turns on, and can stop or withdraw at any time. Withdrawing deletes the saved session.
A banner stays at the top of the screen: "Signals aren't truth." The app never produces a truth, sentiment or health score.
It's a desktop app (Electron + a small local Python backend) running on Windows, macOS and Linux. There's also an experimental native Android version in the repo that I haven't been able to test on a device yet.
Demo
The video shows:
- The participant reading the consent dialog and checking the agreement themselves.
- SmartSpectra starting and the camera preview appearing.
- A live breathing-rate estimate appearing after the first measurement window, then changing as I breathe faster and slower.
- Stepping through prompts, adding a question and attaching an image prompt.
- Withdrawing consent: the camera turns off and the saved copy is deleted.
Code
kit57 / dev_presagechallenge Presage SmartSpectra SDK Challenge on Dev 2026 Signal Session A consent-first interview workspace with an Electron desktop app and a native Android app using Presage SmartSpectra to display a live breathing-rate signal. It is not a lie detector: breathing and other wellness signals do not establish truthfulness and must not be used for diagnosis, treatment, or medical decisions.
View on GitHub
Screenshots
The interview workspace before consent. The camera is off and no breathing estimate is shown until the participant agrees:
The consent dialog the participant reviews before SmartSpectra starts:
Requirements
- Node.js 22.12 or newer
- Python 3.10 or newer
- A SmartSpectra API key from Presage
- A camera for live measurements
The SmartSpectra native runtime currently supports Windows x64, macOS arm64, and Linux x64/arm64. See the SDK documentation for platform requirements.
Project layout
src/renderer/- HTML, styles, and browser-side app code.src/main/- Electron main process and SDK preload bridge.backend/- Python local API and its tests.android/- nativeβ¦
Setup
Setup instructions are in the README. In short:
npm install
cp .env.example .env # then add PRESAGE_API_KEY=your_key
npm start
npm start bundles the frontend, starts the local Python API on 127.0.0.1:8765 and opens the Electron window. You need Node.js 22.12+, Python 3.10+, a webcam and a SmartSpectra API key. npm test runs the backend tests.
How It Responds to Human Signals
Signal used: breathing rate, from the SmartSpectra breathingMetrics bundle. I requested only breathing on purpose. Pulse, HRV and expressions are the signals people most want to read as "nervous" or "lying," and I didn't want the app to make that tempting. Breathing is also easy to see changing in a demo: breathe faster and the number follows.
Integration
SmartSpectra's Node SDK splits work across Electron's processes. The main process binds the SDK's IPC bridge to the window:
const { bindSmartSpectraIpc } = require("@smartspectra/node-sdk/main");
bindSmartSpectraIpc(window);
The renderer creates the SDK only after the participant has agreed. Telemetry is turned off explicitly:
import { breathingMetrics, ProcessingStatus, SmartSpectraSDK } from "@smartspectra/node-sdk/renderer";
import { decodeMetrics } from "@smartspectra/node-sdk/messages";
const sdk = new SmartSpectraSDK({
apiKey,
requestedMetrics: [...breathingMetrics],
enableTelemetry: false,
});
sdk.on("streamAvailable", (stream) => {
cameraVideo.srcObject = stream;
});
sdk.on("validationStatus", (_code, _ts, hint) => {
if (hint) cameraMessage.textContent = hint;
});
sdk.on("metrics", (buffer) => showLiveMetrics(buffer));
await sdk.start();
Responding in real time
Each metrics event is decoded and the newest breathing reading updates the screen:
function showLiveMetrics(buffer) {
const metrics = decodeMetrics(buffer);
const reading = metrics.breathing?.rate?.at(-1);
if (!reading || !Number.isFinite(reading.value)) return;
breathingNumber.textContent = reading.value.toFixed(1);
breathingConfidence.textContent = `Live SDK reading Β· ${reading.confidence.toFixed(0)}% confidence Β· ${reading.stable ? "stable" : "not stable"}`;
updateBreathingTrend(reading); // last 28 readings, kept in memory only
}
The rest of the app responds to the signal as well:
The status badge goes from Starting to Processing to Live SDK signal as SmartSpectra moves through its states. SDK guidance ("move closer," "improve lighting") is shown as it arrives, so the participant can fix the framing themselves. Confidence and stability appear next to every value, so nobody takes an unstable reading at face value. The trend line shows how breathing changes over the conversation, without labeling any moment as good or bad.
The first estimate takes about 30 seconds because breathing needs a full measurement window. The app says so on screen instead of showing a fake number.
Prize Categories
Best Thoughtful Real-World Use
The need: camera-based vital signs are now easy to add to any app, and the first idea many people have (including me) is to use them to judge other people. I wanted to show what a responsible version of that kind of tool looks like: the signal stays visible to both people, the person on camera controls it, and the app is honest about what it can't do.
Who it's for: people running consensual, structured conversations, such as practice interviews, user-research sessions, or anyone curious how their own breathing changes while answering questions.
How I designed it to be usable for them:
Consent is a real gate. Nothing touches the camera until the participant checks the agreement, and the app tells the operator not to agree on the participant's behalf. Both "Not now" and "Withdraw consent" are always one click away.
Clear, short disclosures. The consent dialog lists in plain bullets what the camera does, what's measured, what's saved, for how long, and what isn't saved.
The prompt tools nudge toward fairness. The "Add a question" dialog asks for neutral, open-ended, non-accusatory wording.
Honest output. Every reading shows confidence and stability, and the app repeats that signals aren't truth.
Consent and Data Handling
Camera consent
The camera stays off until the participant reads the disclosure and checks "I am the participant, I am 18 or older, and I voluntarily agree." The agree button is disabled until they do. The camera request is video only; no microphone is requested. Electron only grants camera permission to the app's own local page.
The participant can stop the measurement or withdraw consent at any time. Withdrawing stops SmartSpectra, releases the camera and deletes the saved session. The app doesn't support covert or background monitoring. The live preview is always visible while measuring.
Processing and sharing
SmartSpectra processes the live camera frames through its runtime on the computer. The app doesn't record video. Camera frames and breathing values are never sent to the app's backend or anywhere else. The breathing trend is kept in memory and cleared when the measurement stops.
When a measurement starts, the SDK makes an authentication request to Presage with my API key. For Presage's own handling of that request, see Presage's terms and privacy policy.
Storage, retention and deletion
After consent, the app saves only question prompts and notes, in a local SQLite file (~/.signal-session/sessions.sqlite3). Selected images and videos are previewed in memory and are not saved, and neither are their file names. The local backend only listens on 127.0.0.1 and rejects requests with a non-local Host header, so other websites can't read it through DNS rebinding. Its log shows request paths and status codes, not note contents.
Saved data expires 30 days after the first save, and editing doesn't extend that. Expired data is deleted the next time the app runs. Delete saved copy removes it immediately.
SDK telemetry: turned off (enableTelemetry: false). AI services: none. No LLM or other AI service is used.
What this app is not: it is not a lie detector, and it makes no diagnosis, treatment or medical claims. Breathing rate is a wellness signal and must not be used to decide anything about a person's honesty or health.
Comments
No comments yet. Start the discussion.