build_curve
Converts a market quote strip into an engine curve specification and index definitions for bootstrapping, without pricing anything.
Instructions
Turn a quote strip into an engine curve spec (no engine call).
Args:
id: curve id to register, e.g. USD_SOFR_OIS.
preset: a preset id from list_presets; supplies the index
definition and every helper convention.
quotes: [{type: deposit|fra|future|swap|ois, tenor: "6M", rate: 0.052}, ...]
(fra: months_to_start/months_to_end; future:
future_start_date + price or rate). Sorted by
maturity; a duplicate (type, tenor) is rejected locally.
reference_date: YYYY-MM-DD curve date (normally the pricing as_of).
market_data_source: where the market numbers in this call come from. user_pasted
(the user pasted or typed the numbers in this conversation), user_file (the
user attached a file/screenshot the numbers were read from), engine_example
(an engine example's pricing block, only when the user explicitly asked to run
an example), session (a market previously stored in this session, which
itself came from one of the above). There is no value for estimated, recalled or
placeholder data. If you would have to invent numbers, do not call this tool:
ask the user for the data.
trait: override the preset's bootstrap trait (Discount,
ZeroRate, FwdRate).
interpolator: override the preset's interpolator.
day_counter: override the preset's curve day counter.
Returns {ok, curve, indices, preset, notes}: curve is the
TermStructure and indices the IndexDef list to pass to
bootstrap_curve (or to session_put); notes lists every
default applied with its source. Nothing is priced here.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | ||
| trait | No | ||
| preset | Yes | ||
| quotes | Yes | ||
| day_counter | No | ||
| interpolator | No | ||
| reference_date | Yes | ||
| market_data_source | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||