# Half-Kelly Fraction

> Half-Kelly Fraction is a paid API for AI agents from api.delx.ai, paid per call via x402, $0.001/call, status unknown (last checked 2026-09-15).

Computes the half-Kelly bet sizing fraction given win probability and net odds ratio, returning a conservative Kelly criterion stake for lower-variance bankroll growth.

## Facts

- Endpoint: POST https://api.delx.ai/api/v1/x402/half-kelly
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/half-kelly-fraction-57e0b34c
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_jrk1QlaLD80rUJrhmQ1mI

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability half-kelly-fraction-57e0b34c -d '<json body>'
```

Example prompt: What's the half-Kelly bet size fraction I should use if my win probability is 0.6 and the net odds ratio (b) is 2.0?

## When to prefer this

Use this endpoint when you need a quick, local, deterministic half-Kelly bet sizing calculation with no external dependencies, API keys, or market data feeds. Prefer it over full-Kelly when you want lower variance and more conservative bankroll growth. It is ideal for AI agents doing autonomous position sizing, betting systems, or portfolio allocation where reproducibility and determinism matter and a tiny per-call cost ($0.001 USDC) is acceptable.

## Known failure modes

- Missing or non-numeric win_prob or b fields returns a validation error
- win_prob outside [0,1] range may produce nonsensical or negative fractions
- b <= 0 (non-positive odds) is mathematically invalid and may error
- Payment failure or insufficient USDC balance returns HTTP 402
- If the Kelly formula yields a negative value (unfavorable bet), result may be 0 or negative

## How this service works

Half-Kelly fraction for conservative bankroll growth. Call when agents that want Kelly growth with lower variance. Returns half Kelly fraction as deterministic JSON for $0.001 USDC via x402 on Base. First-party local math only—no RPC, live market feed, API keys, storage, or mediagen. Advisory only; the caller owns capital, risk, and production controls.

## Output

A deterministic JSON object containing the half-Kelly fraction (a number between 0 and 1) representing the conservative fraction of bankroll to stake, computed from the supplied win probability and net odds ratio using local math only.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "b": {
   "type": "number",
   "description": "Input field: b."
  },
  "win_prob": {
   "type": "number",
   "description": "Input field: win prob."
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "b": 1.2,
  "schema": "delx/util-half-kelly/v1",
  "win_prob": 0.55,
  "half_kelly": 0.08750000000000002
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/half-kelly-fraction-57e0b34c/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.delx.ai](https://www.zero.xyz/host/api.delx.ai/llms.txt)
