Expression Measurement API
Measure emotional expression in speech and faces, from recordings you already have or from live audio and video. The audio endpoints score each window of speech, and the video endpoints score the faces in each image or video frame. You can use them to:
- Label a dataset of recorded speech or images
- Evaluate generated audio, such as text-to-speech output
- Route or monitor a live call while it is still going
What it measures
From speech, the API returns expressions such as amusement and vocal qualities such as monotone. From an image, it returns expressions and visible facial actions, such as smile, for the largest faces it detects, 2 by default.
Learn more about the science behind expression measurement in Hume’s research and publications.
Endpoints
Upload endpoints measure media you already have, and realtime endpoints measure media as it streams. For the same media, both return the same measurements. Every endpoint is served from api.cloud.hume.ai, the upload endpoints over https:// and the realtime endpoints over wss://, with your API key in the X-Hume-Api-Key header (see Authentication).
The realtime endpoints share one WebSocket protocol, described in Sessions. Each upload request and realtime session is also recorded as a run, which you can look up later for its status and configuration. Runs do not store measurements, so keep the results you need.
Compatibility
The API version is the path prefix, /v1/. Within a version:
- The server may add fields to the responses and messages it sends. Ignore fields you do not recognize.
- New prediction names may be added. Treat a name you do not recognize as a new prediction, not as an error.
- Requests and messages the client sends are validated strictly. An unrecognized field in a
configpart or asession.updateis rejected withconfig_invalid.