Skip to content

Add CardioPulse — live cardiovascular fitness-test agent (BLE + ASI:One)#153

Open
ishneet42 wants to merge 3 commits into
fetchai:mainfrom
ishneet42:add-cardiopulse-agent
Open

Add CardioPulse — live cardiovascular fitness-test agent (BLE + ASI:One)#153
ishneet42 wants to merge 3 commits into
fetchai:mainfrom
ishneet42:add-cardiopulse-agent

Conversation

@ishneet42

@ishneet42 ishneet42 commented Jun 12, 2026

Copy link
Copy Markdown

Summary

Adds CardioPulse under contributors/cardiopulse-agent/ — a live, stream-driven agent that reads a Garmin watch's heart rate over Bluetooth and runs a timed three-phase autonomic test (resting baseline → orthostatic → paced breathing) entirely through an ASI:One chat. It returns an estimated Cardio Fitness Age with reference ranges, an inline HR-timeline chart, and an ASI-1 coaching summary; repeated runs build a per-user trend.

Two-agent design: a local bridge agent subscribes to the watch's BLE Heart Rate characteristic (Bleak) and POSTs each reading to the main agent, which is registered on Agentverse via mailbox and reachable through ASI:One.

Scope: a proof of concept for a live, stream-driven agent — not a medical device and not health advice. Readings are illustrative estimates (~±5 years); the trend across repeated tests matters more than any single number.

Type of Change

  • New agent example
  • Bug fix
  • Documentation update
  • Refactor / cleanup
  • Other

Checklist

  • I have starred this repository.
  • New community agents are under contributors/<agent-name>/ (not repo root).
  • I ran ruff check ..
  • I ran ruff format ..
  • I added/updated README.md for changed example(s).
  • I added .env.example if environment variables are required.
  • I added demo image/GIF (if applicable).
  • I added agent profile link (if applicable). (The agent address is derived per-deployment from AGENT_SEED; the README documents how to deploy via mailbox.)
  • I updated contributors/CHANGELOG.md for community agent changes.
  • I added my agent to the Community Contributors table in root README.md.
  • I verified paths/commands used in docs.
  • I understand this PR requires maintainer review before merge (review-required CI).

Related Issue

None.

Notes for Reviewers

  • The agent needs local hardware — a Garmin watch broadcasting heart rate over BLE — so the live path can't run headless in CI. test_scoring.py exercises the scoring engine end-to-end with synthetic HR data and runs with no watch (python test_scoring.py).
  • The bridge → agent link uses a localhost REST POST rather than agent-to-agent messaging, because Agentverse mailbox routing is too slow for the 1 Hz heart-rate stream; the mailbox carries the ASI:One conversation. Both agents run on the same machine. This is documented in the agent README's Architecture section.
  • No secrets or personal data are committed; .env.example documents all configuration.

ishneet42 and others added 3 commits June 12, 2026 13:13
A two-agent example under contributors/cardiopulse-agent/ that streams a Garmin watch's heart rate over BLE and runs a three-phase autonomic test (resting baseline, orthostatic, paced breathing) through ASI:One, returning an estimated Cardio Fitness Age with reference ranges, an inline HR chart, and an ASI-1 coaching summary. A local bridge agent reads the watch over BLE and POSTs readings to the mailbox-registered main agent.

Proof of concept for a live, stream-driven agent — not a medical device.
mypy inferred the mixed-value _stats dict as dict[str, object], making the counter increments and comparison invalid. Split the int counters from the last-error string into separate, single-typed containers.
@gautammanak1 gautammanak1 self-assigned this Jun 16, 2026
@gautammanak1 gautammanak1 self-requested a review June 16, 2026 11:54
@gautammanak1

Copy link
Copy Markdown
Collaborator

No description provided.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants