FeaturesTemplatesShowcaseTownie
AI
BlogDocsPricing
Log inSign up
vtTestLocal
vtTestLocala3f9cb081ad_
Public
Like
a3f9cb081ad_
Home
Code
60
dailyBriefing
3
dashboard
4
dbUtils
4
importers
5
shared
1
.cursorrules
README.md
backstory.ts
file0-63af8dd8-d092-48eb-9cd1-f9fec925d8e2.txt
file1-b7584e72-150d-49d9-8b24-3bbd0e3dd065.txt
file10-077019eb-8c63-4479-9cbf-293c07b205ad.txt
file11-57025421-1b44-4245-8438-2c0a8af2ef61.txt
file12-dc737e61-227c-475a-9268-35c9fb19dbd8.txt
file13-14cf5bc1-afef-455a-b540-1b81ebe0a14f.txt
file14-eb5bdfe5-4c91-41b3-98e5-198417cee3d9.txt
file15-ab804af0-0e79-4607-b201-26544c1cc83b.txt
file16-db2aee36-14d8-4caf-970d-b8079d709979.txt
file17-3369bff1-826f-48c1-92c1-9a487bc53990.txt
file18-9310c5d7-af46-4c58-9bb4-c476cc113cd7.txt
file19-a9d6801c-9afa-4966-ac5c-818f880535b3.txt
file2-ab781416-710e-4e9e-828c-013cf74c8664.txt
file20-696a04c1-94e5-4210-8b4d-31da7c9fecae.txt
file21-7ddfcb74-aa65-467f-9c1b-1691902cdb0a.txt
file22-12ebb593-b906-4c0e-b37e-e16f9bb37ce9.txt
file23-0102f377-f423-4a5a-b649-68caabb0d8a2.txt
file24-e85ceca3-d113-43e8-9b3c-85ba995b3ccc.txt
file25-adfc0362-ad3c-4d93-a516-ed14442f2168.txt
file26-6608df14-d890-42d3-b3bd-09eb9c3e980f.txt
file27-55f68104-c57e-4e12-9274-d0d445c1a35c.txt
file28-f5eee6ae-0a52-4eac-91f1-1a726f69611f.txt
file29-3e6c2b38-c269-4396-8665-af0ef3caa2d3.txt
file3-7881a026-7e45-4e05-abd6-6b3f96090e29.txt
file30-a55351e7-a02a-4e62-8378-197b2baf30e4.txt
file31-ea218307-69ea-43d6-b4af-c0fb2edbc48d.txt
file32-06644ced-5ca7-41a7-b992-ad1edf8ef5c4.txt
file33-ed6f404c-379e-467d-91c8-543974bb5eaf.txt
file34-02c48f4b-6cd0-4d85-a281-982f3358193d.txt
file35-8de0da99-c892-4be9-8f76-22ffc71b9db4.txt
file36-60b8b780-7d42-46fb-93c3-0b7a44e9b0b9.txt
file37-63e81d2a-81cf-47be-9db1-118d3c607b7b.txt
file38-cd38db6d-0a4d-461b-a20a-0b22e337d8dd.txt
file39-058864bb-d5ad-4db9-8a0c-08becf8280e3.txt
file4-c1e9b562-a52b-4541-a00d-0ea1381fc8ee.txt
file40-e5a82d3c-2847-4c4a-93fe-9ba4df64329c.txt
file41-b533b1f8-ce4d-4444-b6b9-21e27f08c3ac.txt
file42-8aa91201-0dbd-4d3e-bf36-f161b561afc5.txt
file43-16089c4d-c011-4de1-99dc-af5f7ecec065.txt
file44-0e677137-949d-4843-a857-bad9368ff6eb.txt
file45-da70bddd-472d-45c7-b903-0a53ef2d8445.txt
file46-06fbb038-5162-415b-8026-bea1acaeee45.txt
file47-f64bd899-f411-4e4c-bada-9dd724982ba7.txt
file48-1fff411c-71ec-4fa1-becc-48b9d66ffa68.txt
file49-0853b751-bba0-4439-8260-a0c01b7b8da1.txt
file5-4b9b072c-316e-4f81-9a70-63e405a6f68f.txt
file6-bda07f2d-0287-45e2-bab3-fd5690192ad0.txt
file7-0e793109-f3ed-4310-87f7-cf2602b8adcb.txt
file8-135f7b5d-7d4a-42ee-a8ac-6287194f7c2a.txt
file9-12a9d950-9572-4fc7-8ee6-b2548cdb6aaa.txt
memoryUtils.ts
populateDemo.ts
Branches
1
Pull requests
Remixes
History
Environment variables
Settings
Val Town is a collaborative website to build and scale JavaScript apps.
Deploy APIs, crons, & store data – all from the browser, and deployed in miliseconds.
Sign up now
Code
/
Code
/
Search
https://vtTestLocal--9af9fe1a293211f0b4a9569c3dd06744.web.val.run
README.md

Stevens

"The great butlers are great by virtue of their ability to inhabit their professional role and inhabit it to the utmost; they will not be shaken out by external events, however surprising, alarming or vexing."

— the great butler Stevens, in The Remains of the Day by Kazuo Ishiguro

Stevens is your personal digital butler, ever vigilant and ever helpful in managing the complexities of your digital life.

Much like his literary namesake, he takes great pride in his work, maintaining a dignified and professional demeanor while ensuring your affairs are in perfect order.

In the grand tradition of English butlers, Stevens has been designed to be both unobtrusive and indispensable. His primary duty is to learn about your life's context and provide you with daily briefs that keep you informed while saving you precious time.

Technical Architecture

⚠️ important caveat: the admin dashboard doesn't have auth! currently it just relies on security by obscurity of people not knowing the url to a private val. this is not very secure. if you fork this project and put sensitive data in a database you should think carefully about how to secure it.

Stevens has been designed with the utmost simplicity and extensibility, much like a well-organized household. At the heart of his operation lies a single "memories" table - a digital equivalent of a butler's meticulous records. This table serves as the foundation for all of Stevens' operations.

Core Components

  1. Memories Table: A freeform repository of all that Stevens deems worth remembering, much like a butler's mental catalog of household affairs.

    Schema:

    • id: String - Unique identifier for each memory (generated using nanoid)
    • date: String - Date in ISO format (YYYY-MM-DD)
    • text: String - Content of the memory (e.g., "weather forecast: High of 75, low of 60, partly cloudy")
    • createdBy: String - Source of the memory (e.g., "weather", "email")
    • createdDate: Number - Timestamp in milliseconds when the memory was created
    • tags: String - Categories for organizing memories (e.g., "weather")
  2. Importers: These are Stevens' eyes and ears in the digital world, gathering information from various sources:

    • Weather reports
    • Postal service updates
    • Ingesting messages from email or TElegram
    • And other sources of information that might be of interest to you
  3. Workflows: Stevens' carefully orchestrated routines that utilize his memories to assist you:

    • Morning briefs sent via Telegram or email
    • Responding to questions via text message

Folder layout

  • importers: cron jobs for importing data into the memories table
  • dashboard: the admin view for showing the memories notebook + visualizing imports
  • dailyBriefing: stuff related to sending a daily update via telegram
  • dbUtils: little one-off scripts for database stuff

Hiring your own Stevens

This project isn't intended to be runnable out of the box, but you can adapt it for yourself if you fork the code.

You'll need to set up some environment variables to make it run.

  • ANTHROPIC_API_KEY for LLM calls
  • You'll need to follow these instructions to make a telegram bot, and set TELEGRAM_TOKEN. You'll also need to get a TELEGRAM_CHAT_ID in order to have the bot remember chat contents.
  • For the Google Calendar integration you'll need GOOGLE_CALENDAR_ACCOUNT_ID and GOOGLE_CALENDAR_CALENDAR_ID. See these instuctions for details.

important caveat: the admin dashboard doesn't have auth! currently it just relies on security by obscurity of people not knowing the url to a private val. this is not very secure, if you put sensitive data in a database you should think carefully about how to secure it.

Overall it's a simple enough project that I encourage you to just copy the ideas and run in your own direction rather than try to use it as-is.

HTTP
  • index.ts
    vtTestLocal--9a…44.web.val.run
  • handleTelegramMessage.ts
    vtTestLocal--9a…44.web.val.run
Cron
  • cronDailyBrief.ts
  • generateFunFacts.ts
  • getCalendarEvents.ts
  • getWeather.ts
Email
  • handleUSPSEmail.ts
Code
dailyBriefingdashboarddbUtilsimportersshared.cursorrulesREADME.mdbackstory.tsfile0-63af8dd8-d092-48eb-9cd1-f9fec925d8e2.txtfile1-b7584e72-150d-49d9-8b24-3bbd0e3dd065.txtfile10-077019eb-8c63-4479-9cbf-293c07b205ad.txtfile11-57025421-1b44-4245-8438-2c0a8af2ef61.txtfile12-dc737e61-227c-475a-9268-35c9fb19dbd8.txtfile13-14cf5bc1-afef-455a-b540-1b81ebe0a14f.txtfile14-eb5bdfe5-4c91-41b3-98e5-198417cee3d9.txtfile15-ab804af0-0e79-4607-b201-26544c1cc83b.txtfile16-db2aee36-14d8-4caf-970d-b8079d709979.txtfile17-3369bff1-826f-48c1-92c1-9a487bc53990.txtfile18-9310c5d7-af46-4c58-9bb4-c476cc113cd7.txtfile19-a9d6801c-9afa-4966-ac5c-818f880535b3.txtfile2-ab781416-710e-4e9e-828c-013cf74c8664.txtfile20-696a04c1-94e5-4210-8b4d-31da7c9fecae.txtfile21-7ddfcb74-aa65-467f-9c1b-1691902cdb0a.txtfile22-12ebb593-b906-4c0e-b37e-e16f9bb37ce9.txtfile23-0102f377-f423-4a5a-b649-68caabb0d8a2.txtfile24-e85ceca3-d113-43e8-9b3c-85ba995b3ccc.txtfile25-adfc0362-ad3c-4d93-a516-ed14442f2168.txtfile26-6608df14-d890-42d3-b3bd-09eb9c3e980f.txtfile27-55f68104-c57e-4e12-9274-d0d445c1a35c.txtfile28-f5eee6ae-0a52-4eac-91f1-1a726f69611f.txtfile29-3e6c2b38-c269-4396-8665-af0ef3caa2d3.txtfile3-7881a026-7e45-4e05-abd6-6b3f96090e29.txtfile30-a55351e7-a02a-4e62-8378-197b2baf30e4.txtfile31-ea218307-69ea-43d6-b4af-c0fb2edbc48d.txtfile32-06644ced-5ca7-41a7-b992-ad1edf8ef5c4.txtfile33-ed6f404c-379e-467d-91c8-543974bb5eaf.txtfile34-02c48f4b-6cd0-4d85-a281-982f3358193d.txtfile35-8de0da99-c892-4be9-8f76-22ffc71b9db4.txtfile36-60b8b780-7d42-46fb-93c3-0b7a44e9b0b9.txtfile37-63e81d2a-81cf-47be-9db1-118d3c607b7b.txtfile38-cd38db6d-0a4d-461b-a20a-0b22e337d8dd.txtfile39-058864bb-d5ad-4db9-8a0c-08becf8280e3.txtfile4-c1e9b562-a52b-4541-a00d-0ea1381fc8ee.txtfile40-e5a82d3c-2847-4c4a-93fe-9ba4df64329c.txtfile41-b533b1f8-ce4d-4444-b6b9-21e27f08c3ac.txtfile42-8aa91201-0dbd-4d3e-bf36-f161b561afc5.txtfile43-16089c4d-c011-4de1-99dc-af5f7ecec065.txtfile44-0e677137-949d-4843-a857-bad9368ff6eb.txtfile45-da70bddd-472d-45c7-b903-0a53ef2d8445.txtfile46-06fbb038-5162-415b-8026-bea1acaeee45.txtfile47-f64bd899-f411-4e4c-bada-9dd724982ba7.txtfile48-1fff411c-71ec-4fa1-becc-48b9d66ffa68.txtfile49-0853b751-bba0-4439-8260-a0c01b7b8da1.txtfile5-4b9b072c-316e-4f81-9a70-63e405a6f68f.txtfile6-bda07f2d-0287-45e2-bab3-fd5690192ad0.txtfile7-0e793109-f3ed-4310-87f7-cf2602b8adcb.txtfile8-135f7b5d-7d4a-42ee-a8ac-6287194f7c2a.txtfile9-12a9d950-9572-4fc7-8ee6-b2548cdb6aaa.txtmemoryUtils.tspopulateDemo.ts
Go to top
X (Twitter)
Discord community
GitHub discussions
YouTube channel
Bluesky
Product
FeaturesPricing
Developers
DocsStatusAPI ExamplesNPM Package Examples
Explore
ShowcaseTemplatesNewest ValsTrending ValsNewsletter
Company
AboutBlogCareersBrandhi@val.town
Terms of usePrivacy policyAbuse contact
© 2025 Val Town, Inc.