Skip to content

Guide · Agent skill

How to use the Event-Driven Trading Signals agent skill

Updated · written with AI from the project's own documentation and checked against our catalogue data

This guide explains what the event-driven agent skill from HKUDS/Vibe-Trading does, how to install it, and how to ask an AI agent to use it. It is written for readers who have not used agent skills before. By the end you will know how the agent turns news into scored event data, how that data is decayed over time and blended with a technical signal, and what limits to keep in mind for backtesting.

Event-Driven Trading SignalsHKUDS/Vibe-Trading · MIT

Quick start

  1. 1Install the skill. Download the ZIP from this page and unzip it into ~/.claude/skills/ or a project's .claude/skills/ folder, or upload it under Settings → Capabilities → Skills in the Claude apps.
  2. 2Check your environment. Confirm Python with numpy and pandas is available, and that the agent has a read_url tool or equivalent and an LLM for scoring.
  3. 3Fetch the news. Ask the agent to collect the full text of the relevant news and announcements for your instrument and period using read_url.
  4. 4Score each item. The LLM scores every item from -1.0 to 1.0 with the standardized prompt, returning one number per item.
  5. 5Write the event CSV. Save the results in the date,event_type,score,source,summary schema, using knowable dates and comma-free summaries.
  6. 6Aggregate the signal. Run the signal engine to apply decay with the default parameters and combine the result with the technical signal at alpha 0.6.
  7. 7Review the backtest. Check for look-ahead bias and duplicate events before trusting the combined signal.

What is an agent skill and what does this one do?

An agent skill is a folder of instructions and optional scripts that an AI agent can load when a task matches it. This skill, named event-driven, teaches the agent to run an event-driven trading strategy. It is licensed under MIT.

The agent reads news, announcements, and macro policy updates, then scores each item from -1.0 (extremely bearish) to 1.0 (extremely bullish) using a fixed prompt. The scores are saved in a standard CSV file. The skill then applies time decay so older events count less, and combines the event signal with a technical signal.

  • Fetches full article text from URLs with a read_url tool or equivalent
  • Scores sentiment with an LLM using a standardized prompt
  • Writes events in the date,event_type,score,source,summary CSV schema
  • Applies exponential decay and a weighted blend of technical and event signals

How do you install the event-driven skill?

You can install the skill in either of two ways. For Claude Code, download the ZIP from the skill's page on this directory and unzip it into your user skills folder at ~/.claude/skills/, or into a project's .claude/skills/ folder if you want it limited to one project.

In the Claude apps, you can instead upload the ZIP under Settings → Capabilities → Skills. After installing, start a new session so the agent can see the skill.

  • User-wide install: unzip into ~/.claude/skills/
  • Project install: unzip into the project's .claude/skills/ folder
  • Claude apps: upload the ZIP under Settings → Capabilities → Skills
~/.claude/skills/event-driven/

What do you need before you start?

The skill assumes a working quantitative setup. The example engine uses Python with numpy and pandas. The agent also needs a read_url tool, or an equivalent way to fetch web pages, and an LLM to perform the sentiment scoring.

If you want to run the example engine, you also need the Vibe-Trading backtest loaders (rsshub_events) and an event_feeds entry in your backtest config. The skill does not supply a data source, so you must have historical news with correct publication dates.

  • Python with numpy and pandas
  • A read_url tool or equivalent for fetching news pages
  • An LLM for sentiment scoring
  • For the example engine: the Vibe-Trading rsshub_events loaders and an event_feeds entry in the backtest config
  • Historical, correctly dated news for any backtest

How do you trigger the skill with a natural request?

You do not need a special command. Describe the task in plain language and mention news, events, or sentiment, and the agent should pick up the skill. Be specific about the instrument and the period so the agent knows which data to fetch and which backtest to build.

Good requests name the goal, the data, and the output. For example, ask for scored events for one stock over a date range, or ask for a combined signal with a stated weight.

  • Score the news about [ticker] from [start] to [end] and save it to the event CSV
  • Build an event-driven signal for [ticker] with decay 0.1 and a 30-day lookback
  • Combine my technical signal with the event signal using the default 60/40 weights and show the result

How does the scoring and signal calculation work?

The LLM scores each article with the standardized prompt in the skill. The scale runs from extremely bearish to extremely bullish, and the prompt asks for one number only. Keeping the prompt fixed keeps scores consistent across items.

The engine then keeps events whose absolute score is at least 0.2, weights each by exp(-0.1 × days), sums them, and clips the total to [-1, 1]. Events older than 30 days are excluded. Finally, the combined signal is 0.6 × technical plus 0.4 × event, clipped to [-1, 1].

  • alpha = 0.6: technical weight, so event weight is 1 - alpha = 0.4
  • decay_lambda = 0.1: about 37% of the impact remains after 10 days
  • event_lookback = 30: older events are dropped
  • min_score_threshold = 0.2: weak scores are ignored
combined = alpha * tech_signal + (1 - alpha) * event_signal

What does the event CSV look like?

Each row is one event. The date column should be the date the event became knowable, which is the publication date rather than the date it occurred. If an item is released after market close, use the next trading day. The event_type must be one of earnings, macro, policy, sentiment, insider, or technical_break.

Keep the summary to one sentence without commas, because commas can break CSV parsing. If you must use commas, read the file with quoting set to csv.QUOTE_ALL.

  • date: YYYY-MM-DD, the knowable date
  • event_type: earnings, macro, policy, sentiment, insider, or technical_break
  • score: a float from -1.0 to 1.0
  • source: a tag such as read_url
  • summary: one sentence with no commas
date,event_type,score,source,summary 2024-01-15,earnings,0.8,read_url,Q4 revenue beat expectations by 30%

What mistakes should you avoid?

The most important risk is look-ahead bias. Only use events with date on or before the trade date. Duplicate coverage is also common: the same event can appear from several sources, so deduplicate by (date, event_type) or average the scores.

Most trading days will have no events, and that is normal. Do not invent events to fill gaps. Historical backtests also need a complete event file prepared in advance, since it cannot be fetched in real time. The skill notes that the LLM scoring standard can drift when the prompt or model changes, so fix the prompt and recalibrate regularly.

  • Enforce event_date <= trade_date in every backtest
  • Deduplicate events by (date, event_type) or average their scores
  • Expect many days with no event; the technical signal then drives the result
  • Keep separate event files per instrument
  • Fix the prompt template and recalibrate when the model changes

What people use it for

  • Testing whether news sentiment improves a price-based strategy compared with technicals alone
  • Building a backtest with point-in-time-safe event data for one instrument
  • Comparing decay settings to see how quickly event effects should fade for your data
  • Teaching students how event signals, decay, and look-ahead bias interact

Frequently asked questions

How do I install the event-driven agent skill?

Download the ZIP from the skill's page and unzip it into ~/.claude/skills/ for all projects, or into a project's .claude/skills/ folder for one project. In the Claude apps, upload the ZIP under Settings → Capabilities → Skills instead.

What do I need to run the event-driven skill?

You need Python with numpy and pandas, a read_url tool or equivalent for fetching news pages, and an LLM to score sentiment. The example engine also needs the Vibe-Trading backtest loaders and an event_feeds entry in the backtest config.

Is the event-driven skill free to use?

The skill is listed under the MIT licence. Check the licence file in the source repository for the full terms, and check any costs for the LLM, data, or tools you connect it to.

Can I use this skill for live trading?

The skill is framed as backtesting support, not investment advice. The scores come from an LLM reading news, which can be wrong or biased, so it is not suited to making live trading decisions on its own.

Why does my event signal look like it is always zero?

Most trading days have no events, so the event signal is zero on those days and the final signal relies mainly on technicals. Also check that your event CSV dates are on or before the trade dates and that scores meet the 0.2 minimum threshold.

How does this compare with other sentiment or news trading tools?

This skill focuses on a specific method: LLM-scored events in a fixed CSV schema, exponential decay, and a weighted blend with technical signals. It does not provide a data source, so you must bring historical dated news. Pick another tool if you need a ready-made data feed or live trading execution.

New agent skills, repos and AI tools — every week

The best new skills and open-source projects, the fastest-growing repos, and one free prompt. Five minutes to read. Unsubscribe anytime.

Our verdict

This skill suits quantitative researchers, developers building point-in-time-safe backtests, and students learning how event signals and decay work. It is not suited to live trading or to anyone without correctly dated historical news and a backtest setup. Treat the LLM scores as a hypothesis to test, not as investment advice.

Download the skill