Personalization Use Cases

Device

Fastino automatically infers device context from event metadata (such as email headers, API clients, or session sources), so you can query device data directly without explicit ingestion.

Overview

Device information helps agents understand how and where a user interacts with your system.
It’s useful for adapting output formats, routing messages to the right platform, or building analytics dashboards.

The API supports:

  • Fetching the user’s current or most active device.

  • Retrieving deterministic summaries of device usage.

  • Asking natural-language questions about device patterns or context.

Endpoints Used

Endpoint

Description

POST /query

Ask a natural-language question about device data.

GET /summary

Retrieve a structured summary of known user devices.

Example: Get Current Active Device

You can query Fastino to find which device a user is currently active on.

POST /query
{
  "user_id": "usr_42af7c",
  "question": "Which device is Ash currently using?"
}

Response

{
  "answer": "Ash is currently active on an iPhone 15 Pro running iOS 18."
}

The response reflects Fastino’s inferred active device based on recent user activity.

Example: Retrieve All Known Devices

To get a structured overview of the user’s device ecosystem, call:

Response

{
  "summary": "Ash primarily uses a MacBook Pro (macOS) for work sessions and an iPhone 15 Pro (iOS 18) for mobile tasks. Typical pattern: laptop 9–5 PT, mobile evenings and weekends."
}

The summary is deterministic and suitable for downstream LLM or analytics use.

Example: Ask About Device Usage Patterns

You can ask open-ended questions to retrieve user-specific insights.

POST /query
{
  "user_id": "usr_42af7c",
  "question": "What devices does Ash use most often, and when?"
}

Response

{
  "answer": "Ash mainly works from a MacBook during office hours and switches to iPhone in the evenings for async communication."
}

Fastino uses temporal and behavioral data to infer device context automatically.

Example Implementation (Python)

import requests

BASE_URL = "https://api.fastino.ai"
HEADERS = {"Authorization": "x-api-key: sk_live_456", "Content-Type": "application/json"}

def get_device_summary(user_id):
    r = requests.get(f"{BASE_URL}/summary?user_id={user_id}&purpose=device", headers=HEADERS)
    return r.json()["summary"]

def query_device_context(user_id, question):
    payload = {"user_id": user_id, "question": question}
    r = requests.post(f"{BASE_URL}/query", json=payload, headers=HEADERS)
    return r.json()["answer"]

# Example usage
print(get_device_summary("usr_42af7c"))
print(query_device_context("usr_42af7c", "Which device is Ash currently using?"))

Integration Ideas

Scenario

Example

Cross-Device Agents

Detect when a user switches from mobile to desktop and adapt response length or tone.

Delivery Optimization

Send quick reminders to mobile, detailed summaries to desktop.

User Analytics

Display which devices a user interacts with most frequently.

Proactive Assistants

Adjust behavior dynamically based on active device (e.g., mobile-friendly phrasing).

Best Practices

  • Use purpose=device summaries for deterministic, structured results.

  • Combine device summaries with Situational Awareness for richer context.

  • Avoid manually tagging devices unless your system requires precise tracking — Fastino infers device type automatically.

  • Cache device summaries for the session; re-fetch periodically for live accuracy.

  • Keep user-facing prompts short and neutral when referencing device state.

Example: Deterministic Device Summary

Response

{
  "summary": "Ash’s typical devices include a MacBook Pro (macOS) and iPhone 15 Pro (iOS 18). Current device: iPhone. Most productive hours occur on desktop during 9–5 PT."
}

Summary

The Device endpoint gives developers direct insight into the user’s device environment — including current active device and typical usage patterns.

Because Fastino infers device data automatically, no explicit ingestion is required.
This makes it easy to deliver device-aware personalization for notifications, agents, and multi-platform experiences.

Next, continue to Personalization Use Cases → Tool to learn how to retrieve and interpret information about the software or applications a user works in most frequently.

On this page