From ac65f74b764971a0894e34983e76ff21f5fad8a7 Mon Sep 17 00:00:00 2001 From: Jabez Vettriselvan Date: Thu, 16 Apr 2026 12:06:00 +0530 Subject: [PATCH 1/4] Update docs for recent Pine v6 features --- LLM_MANIFEST.md | 38 +++++++++++-- Pine Script language reference manual | 77 ++++++++++++++++++++++++++- README.md | 16 ++++++ pinescriptv6_complete_reference.md | 77 ++++++++++++++++++++++++++- reference/functions/general.md | 38 +++++++++++++ reference/types.md | 33 +++++++++++- writing_scripts/style_guide.md | 34 +++++++++--- 7 files changed, 299 insertions(+), 14 deletions(-) diff --git a/LLM_MANIFEST.md b/LLM_MANIFEST.md index 3bb10b1..762f741 100644 --- a/LLM_MANIFEST.md +++ b/LLM_MANIFEST.md @@ -6,6 +6,14 @@ 2. Locate the relevant file path below. 3. Retrieve ONLY that file to conserve context window. +## 0. Latest Release Updates + +*Use these files first when the user asks about recently added Pine v6 features from the release notes.* + +* **`release_notes.md`** + * **Content:** Chronological summary of recent Pine Script v6 additions and behavior changes. + * **Keywords:** `request.footprint`, `volume_row`, `syminfo.isin`, `timeframe_bars_back`, `line wrapping`. + ## 1. Syntax and Core Concepts *Use these files when the user asks about language mechanics, execution flow, or type errors.* @@ -32,7 +40,7 @@ * **`reference/variables.md`** * **Content:** Built-in read-only variables regarding the bar, symbol, or status. - * **Keywords:** `open`, `high`, `low`, `close`, `volume`, `time`, `syminfo.ticker`, `timeframe.multiplier`, `bar_index`. + * **Keywords:** `open`, `high`, `low`, `close`, `volume`, `time`, `syminfo.ticker`, `syminfo.isin`, `timeframe.multiplier`, `bar_index`. * **`reference/constants.md`** * **Content:** Fixed constants used as arguments for functions. @@ -40,7 +48,7 @@ * **`reference/types.md`** * **Content:** Data type definitions and type-casting functions. - * **Keywords:** `int`, `float`, `bool`, `color`, `string`, `line`, `label`, `box`, `simple`, `series`, `input`. + * **Keywords:** `int`, `float`, `bool`, `color`, `string`, `line`, `label`, `box`, `footprint`, `volume_row`, `simple`, `series`, `input`. * **`reference/keywords.md`** * **Content:** Language keywords and control structures. @@ -60,7 +68,7 @@ * **`reference/functions/request.md` (External Data)** * **Content:** Requesting data from other symbols, financial data, or seeds. - * **Keywords:** `request.security`, `request.financial`, `request.seed`, `request.currency_rate`. + * **Keywords:** `request.security`, `request.financial`, `request.footprint`, `request.seed`, `request.currency_rate`. * **`reference/functions/drawing.md` (Visuals)** * **Content:** Plotting data on the chart and drawing geometric shapes. @@ -71,8 +79,12 @@ * **Keywords:** `array.new`, `array.push`, `matrix.new`, `matrix.mult`, `map.new`, `map.put`. * **`reference/functions/general.md` (Math, Strings, Inputs)** - * **Content:** Core math, string manipulation, and user inputs. - * **Keywords:** `math.abs`, `math.round`, `str.tostring`, `str.format`, `input.int`, `input.bool`, `alert()`. + * **Content:** Core built-ins and general-purpose functions, including `time()` / `time_close()` behavior updates. + * **Keywords:** `time`, `time_close`, `bars_back`, `timeframe_bars_back`, `math.abs`, `math.round`, `str.tostring`, `str.format`, `input.int`, `input.bool`, `alert()`. + +* **`writing_scripts/style_guide.md`** + * **Content:** Formatting conventions, including the updated line-wrapping rules for wrapped expressions in parentheses. + * **Keywords:** `style guide`, `line wrapping`, `parentheses`, `indentation`. ## ๐Ÿงญ Routing Logic for LLMs @@ -90,3 +102,19 @@ * **IF** user asks "Why is my variable resetting every bar?": * retrieve `concepts/execution_model.md` (check `var` usage) + +* **IF** user asks about `request.footprint()`, `footprint`, `volume_row`, or footprint imbalance logic: + * retrieve `release_notes.md` + * retrieve `reference/functions/request.md` + * retrieve `reference/types.md` + +* **IF** user asks about `syminfo.isin`: + * retrieve `release_notes.md` + * retrieve `reference/variables.md` + +* **IF** user asks about `timeframe_bars_back` in `time()` or `time_close()`: + * retrieve `release_notes.md` + * retrieve `reference/functions/general.md` + +* **IF** user asks about multiline formatting or indentation rules: + * retrieve `writing_scripts/style_guide.md` diff --git a/Pine Script language reference manual b/Pine Script language reference manual index e06c9fb..1d74a67 100644 --- a/Pine Script language reference manual +++ b/Pine Script language reference manual @@ -1148,6 +1148,17 @@ A sector is a broad section of the economy. An industry is a narrower classifica --- +## syminfo.isin + +**Type:** simple string + +Holds a string representing the symbol's International Securities Identification Number (ISIN), or an empty string if no ISIN information is available. The ISIN is a 12-character code that identifies a security globally and does not vary across exchanges. + +### Remarks +Programmers can use `syminfo.isin` to identify an underlying instrument regardless of exchange-specific ticker naming. For example, `NASDAQ:AAPL` and `GETTEX:APC` share the same ISIN because they refer to the same Apple common stock. + +--- + ## syminfo.main_tickerid **Type:** simple string @@ -8857,6 +8868,34 @@ plot(f) --- +## request.footprint() + +Requests the ID of a footprint object that contains volume footprint data for the current chart bar. + +### Returns +The ID of a `footprint` object, or `na` if no footprint data is available. + +### Remarks +Scripts can use the returned ID with `footprint.*()` functions to retrieve footprint-wide values such as buy volume, sell volume, delta, and special rows such as `poc()`, `vah()`, and `val()`. Scripts can then use the returned `volume_row` IDs with `volume_row.*()` functions to inspect row boundaries and imbalance information. + +Only accounts with Premium or Ultimate plans can use scripts that call this function. + +A single script cannot include more than one `request.footprint()` call. + +### Code Example +```pine +//@version=6 +indicator("Footprint summary", overlay = true) + +footprint fp = request.footprint(100, 70) + +if not na(fp) + volume_row pocRow = fp.poc() + label.new(bar_index, high, str.format("Delta: {0}\nPOC: {1}", fp.delta(), pocRow.up_price())) +``` + +--- + ## request.quandl() Note: This function has been deprecated due to the API change from NASDAQ Data Link. Requests for "QUANDL" symbols are no longer valid and requests for them return a runtime error. @@ -12539,7 +12578,7 @@ plot(standardChartValue, color = color.green) ## time() -The time function returns the UNIX time of the current bar for the specified timeframe and session or NaN if the time point is out of session. +The time function returns the UNIX time of the bar open for the specified timeframe, session, and timezone, or na if the time point is out of session. ### Returns UNIX time. @@ -12547,6 +12586,11 @@ UNIX time. ### Remarks UNIX time is the number of milliseconds that have elapsed since 00:00:00 UTC, 1 January 1970. +The function also supports a `timeframe_bars_back` parameter. Unlike `bars_back`, which offsets on the script's main timeframe, `timeframe_bars_back` offsets on the requested timeframe itself. If both parameters are present, Pine applies `bars_back` first and then applies `timeframe_bars_back`. + +### Signatures +`time(timeframe, session, timezone, bars_back, timeframe_bars_back) โ†’ series int` + ### Code Example ```pine //@version=6 @@ -12568,6 +12612,10 @@ bgcolor(not na(t1) ? color.new(color.blue, 90) : na) indicator("Time", overlay=true) t1 = time(timeframe.period, "1000-1100,1400-1500:23456") bgcolor(not na(t1) ? color.new(color.blue, 90) : na) + +//@version=6 +indicator("`timeframe_bars_back` demo") +plot(time("1M", bars_back = 10, timeframe_bars_back = 3)) ``` --- @@ -12582,12 +12630,21 @@ UNIX time. ### Remarks UNIX time is the number of milliseconds that have elapsed since 00:00:00 UTC, 1 January 1970. +The function also supports a `timeframe_bars_back` parameter. Unlike `bars_back`, which offsets on the script's main timeframe, `timeframe_bars_back` offsets on the requested timeframe itself. If both parameters are present, Pine applies `bars_back` first and then applies `timeframe_bars_back`. + +### Signatures +`time_close(timeframe, session, timezone, bars_back, timeframe_bars_back) โ†’ series int` + ### Code Example ```pine //@version=6 indicator("Time", overlay=true) t1 = time_close(timeframe.period, "1200-1300", "America/New_York") bgcolor(not na(t1) ? color.new(color.blue, 90) : na) + +//@version=6 +indicator("`time_close()` `timeframe_bars_back` demo") +plot(time_close("1M", bars_back = 10, timeframe_bars_back = 3)) ``` --- @@ -13327,6 +13384,24 @@ plot(f) --- +## footprint + +Keyword used to explicitly declare the `footprint` type of a variable or parameter. Scripts create objects of this type by calling `request.footprint()`. + +### Remarks +Scripts can use `footprint` IDs with `footprint.*()` functions to retrieve volume footprint totals, delta values, and row references such as `poc()`, `vah()`, and `val()`. + +--- + +## volume_row + +Keyword used to explicitly declare the `volume_row` type of a variable or parameter. Scripts obtain objects of this type from `footprint` instances. + +### Remarks +Scripts can use `volume_row` IDs with `volume_row.*()` functions to retrieve row price boundaries and detect buy or sell imbalances for individual footprint rows. + +--- + ## int Keyword used to explicitly declare the "int" (integer) type of a variable or a parameter. diff --git a/README.md b/README.md index c24cd54..f44cbd3 100644 --- a/README.md +++ b/README.md @@ -3,6 +3,22 @@ **Current Version:** v6 **Source:** [TradingView Pine Scriptโ„ข v6 Reference Manual](https://www.tradingview.com/pine-script-reference/v6/) & [Welcome to Pine Scriptยฎ v6](https://www.tradingview.com/pine-script-docs/welcome/) +## Recent Release Coverage +The repository now explicitly surfaces the additions documented in [release_notes.md](https://github.com/jabez4jc/pinescriptv6/blob/main/release_notes.md): + +- `request.footprint()` and the `footprint` / `volume_row` types +- `syminfo.isin` +- `time()` / `time_close()` support for `timeframe_bars_back` +- Updated line-wrapping rules for expressions enclosed in parentheses + +These updates are reflected in: + +- [reference/functions/request.md](https://github.com/jabez4jc/pinescriptv6/blob/main/reference/functions/request.md) +- [reference/functions/general.md](https://github.com/jabez4jc/pinescriptv6/blob/main/reference/functions/general.md) +- [reference/types.md](https://github.com/jabez4jc/pinescriptv6/blob/main/reference/types.md) +- [reference/variables.md](https://github.com/jabez4jc/pinescriptv6/blob/main/reference/variables.md) +- [writing_scripts/style_guide.md](https://github.com/jabez4jc/pinescriptv6/blob/main/writing_scripts/style_guide.md) + ## ๐Ÿค– What is this? This repository contains the official Pine Script v6 documentation, restructured and "chunked" specifically for Large Language Models (LLMs). diff --git a/pinescriptv6_complete_reference.md b/pinescriptv6_complete_reference.md index f5d3587..e684c70 100644 --- a/pinescriptv6_complete_reference.md +++ b/pinescriptv6_complete_reference.md @@ -1147,6 +1147,17 @@ A sector is a broad section of the economy. An industry is a narrower classifica --- +## syminfo.isin + +**Type:** simple string + +Holds a string representing the symbol's International Securities Identification Number (ISIN), or an empty string if no ISIN information is available. The ISIN is a 12-character code that identifies a security globally and does not vary across exchanges. + +### Remarks +Programmers can use `syminfo.isin` to identify an underlying instrument regardless of exchange-specific ticker naming. For example, `NASDAQ:AAPL` and `GETTEX:APC` share the same ISIN because they refer to the same Apple common stock. + +--- + ## syminfo.main_tickerid **Type:** simple string @@ -8859,6 +8870,34 @@ plot(f) --- +## request.footprint() + +Requests the ID of a footprint object that contains volume footprint data for the current chart bar. + +### Returns +The ID of a `footprint` object, or `na` if no footprint data is available. + +### Remarks +Scripts can use the returned ID with `footprint.*()` functions to retrieve footprint-wide values such as buy volume, sell volume, delta, and special rows such as `poc()`, `vah()`, and `val()`. Scripts can then use the returned `volume_row` IDs with `volume_row.*()` functions to inspect row boundaries and imbalance information. + +Only accounts with Premium or Ultimate plans can use scripts that call this function. + +A single script cannot include more than one `request.footprint()` call. + +### Code Example +```pine +//@version=6 +indicator("Footprint summary", overlay = true) + +footprint fp = request.footprint(100, 70) + +if not na(fp) + volume_row pocRow = fp.poc() + label.new(bar_index, high, str.format("Delta: {0}\nPOC: {1}", fp.delta(), pocRow.up_price())) +``` + +--- + ## request.quandl() Note: This function has been deprecated due to the API change from NASDAQ Data Link. Requests for "QUANDL" symbols are no longer valid and requests for them return a runtime error. @@ -12541,7 +12580,7 @@ plot(standardChartValue, color = color.green) ## time() -The time function returns the UNIX time of the current bar for the specified timeframe and session or NaN if the time point is out of session. +The time function returns the UNIX time of the bar open for the specified timeframe, session, and timezone, or na if the time point is out of session. ### Returns UNIX time. @@ -12549,6 +12588,11 @@ UNIX time. ### Remarks UNIX time is the number of milliseconds that have elapsed since 00:00:00 UTC, 1 January 1970. +The function also supports a `timeframe_bars_back` parameter. Unlike `bars_back`, which offsets on the script's main timeframe, `timeframe_bars_back` offsets on the requested timeframe itself. If both parameters are present, Pine applies `bars_back` first and then applies `timeframe_bars_back`. + +### Signatures +`time(timeframe, session, timezone, bars_back, timeframe_bars_back) โ†’ series int` + ### Code Example ```pine //@version=6 @@ -12570,6 +12614,10 @@ bgcolor(not na(t1) ? color.new(color.blue, 90) : na) indicator("Time", overlay=true) t1 = time(timeframe.period, "1000-1100,1400-1500:23456") bgcolor(not na(t1) ? color.new(color.blue, 90) : na) + +//@version=6 +indicator("`timeframe_bars_back` demo") +plot(time("1M", bars_back = 10, timeframe_bars_back = 3)) ``` --- @@ -12584,12 +12632,21 @@ UNIX time. ### Remarks UNIX time is the number of milliseconds that have elapsed since 00:00:00 UTC, 1 January 1970. +The function also supports a `timeframe_bars_back` parameter. Unlike `bars_back`, which offsets on the script's main timeframe, `timeframe_bars_back` offsets on the requested timeframe itself. If both parameters are present, Pine applies `bars_back` first and then applies `timeframe_bars_back`. + +### Signatures +`time_close(timeframe, session, timezone, bars_back, timeframe_bars_back) โ†’ series int` + ### Code Example ```pine //@version=6 indicator("Time", overlay=true) t1 = time_close(timeframe.period, "1200-1300", "America/New_York") bgcolor(not na(t1) ? color.new(color.blue, 90) : na) + +//@version=6 +indicator("`time_close()` `timeframe_bars_back` demo") +plot(time_close("1M", bars_back = 10, timeframe_bars_back = 3)) ``` --- @@ -13333,6 +13390,24 @@ plot(f) --- +## footprint + +Keyword used to explicitly declare the `footprint` type of a variable or parameter. Scripts create objects of this type by calling `request.footprint()`. + +### Remarks +Scripts can use `footprint` IDs with `footprint.*()` functions to retrieve volume footprint totals, delta values, and row references such as `poc()`, `vah()`, and `val()`. + +--- + +## volume_row + +Keyword used to explicitly declare the `volume_row` type of a variable or parameter. Scripts obtain objects of this type from `footprint` instances. + +### Remarks +Scripts can use `volume_row` IDs with `volume_row.*()` functions to retrieve row price boundaries and detect buy or sell imbalances for individual footprint rows. + +--- + ## int Keyword used to explicitly declare the "int" (integer) type of a variable or a parameter. diff --git a/reference/functions/general.md b/reference/functions/general.md index 8b13789..bd4910f 100644 --- a/reference/functions/general.md +++ b/reference/functions/general.md @@ -1 +1,39 @@ +### time() +Returns the UNIX time of the bar open for a specified timeframe, session, and timezone, or `na` if the requested time point is outside the session. + +Syntax + +`time(timeframe, session, timezone, bars_back, timeframe_bars_back) โ†’ series int` + +Arguments + +- `timeframe (series string)`: The timeframe to evaluate. Use `timeframe.period` or `""` to inherit the active timeframe. +- `session (series string)`: Optional session string used to filter returned timestamps. +- `timezone (series string)`: Optional timezone used when evaluating the session. +- `bars_back (series int)`: Optional offset on the script's main timeframe. +- `timeframe_bars_back (series int)`: Optional offset on the requested timeframe. Positive values move backward on the requested timeframe. Negative values move forward on the requested timeframe. + +Remarks + +If a call includes both `bars_back` and `timeframe_bars_back`, Pine first applies `bars_back` on the script's main timeframe and then applies `timeframe_bars_back` on the requested timeframe. + +### time_close() + +Returns the UNIX time of the bar close for a specified timeframe, session, and timezone, or `na` if the requested time point is outside the session. On tick charts and price-based charts such as Renko, line break, Kagi, point & figure, and range, this function returns `na` for the latest realtime bar because the future closing time is unpredictable. + +Syntax + +`time_close(timeframe, session, timezone, bars_back, timeframe_bars_back) โ†’ series int` + +Arguments + +- `timeframe (series string)`: The timeframe to evaluate. Use `timeframe.period` or `""` to inherit the active timeframe. +- `session (series string)`: Optional session string used to filter returned timestamps. +- `timezone (series string)`: Optional timezone used when evaluating the session. +- `bars_back (series int)`: Optional offset on the script's main timeframe. +- `timeframe_bars_back (series int)`: Optional offset on the requested timeframe. Positive values move backward on the requested timeframe. Negative values move forward on the requested timeframe. + +Remarks + +If a call includes both `bars_back` and `timeframe_bars_back`, Pine first applies `bars_back` on the script's main timeframe and then applies `timeframe_bars_back` on the requested timeframe. diff --git a/reference/types.md b/reference/types.md index 075d112..db3f166 100644 --- a/reference/types.md +++ b/reference/types.md @@ -137,7 +137,38 @@ plot(f) --- ## footprint -A keyword that explicitly declares the type of a variable or parameter as footprint. Scripts create objects of the footprint type by calling the request.footprint() function. Scripts can use IDs of this type with the built-in footprint.*() functions to retrieve volume footprint data, including footprint rows, categorized volume sums, and volume delta. +A keyword that explicitly declares the type of a variable or parameter as footprint. Scripts create objects of this type by calling `request.footprint()`. + +### Remarks +Scripts can use `footprint` IDs with the built-in `footprint.*()` functions to retrieve: + +- overall footprint values such as buy volume, sell volume, and delta +- row references such as the Point of Control (`poc()`) and Value Area boundaries (`vah()` / `val()`) +- row-by-row volume information through returned `volume_row` IDs + +### Code Example +```pine +//@version=6 +indicator("Footprint summary") + +footprint fp = request.footprint(100, 70) + +if not na(fp) + float buyVolume = fp.buy_volume() + float sellVolume = fp.sell_volume() + float deltaVolume = fp.delta() + volume_row pocRow = fp.poc() + label.new(bar_index, high, str.format("Buy: {0}\nSell: {1}\nDelta: {2}\nPOC high: {3}", buyVolume, sellVolume, deltaVolume, pocRow.up_price())) +``` + +--- + +## volume_row + +A keyword that explicitly declares the type of a variable or parameter as `volume_row`. Scripts obtain objects of this type from `footprint` instances, such as from `poc()`, `vah()`, and `val()`. + +### Remarks +Scripts can use `volume_row` IDs with the built-in `volume_row.*()` functions to retrieve row boundaries, inspect row-level imbalance flags, and work with the volume information for an individual footprint row. ## int diff --git a/writing_scripts/style_guide.md b/writing_scripts/style_guide.md index 19cd2e5..4f453cf 100644 --- a/writing_scripts/style_guide.md +++ b/writing_scripts/style_guide.md @@ -210,20 +210,42 @@ plot(close, color = color.red) ## [Line wrapping](https://www.tradingview.com/pine-script-docs/writing/style-guide/#line-wrapping) -Line wrapping can make long lines easier to read. Line wraps are defined by using an indentation level that is not a multiple of four, as four spaces or a tab are used to define local blocks. Here we use two spaces: +Line wrapping can make long lines of code easier to read by defining a single line of code across multiple lines in the script. + +Generally, scripts can wrap lines using any indentation length that is not a multiple of four, because four spaces or a tab define local blocks in Pine. + +However, if a wrapped line is enclosed in parentheses, such as in function calls, arithmetic expressions, or parameter declarations, it can use any indentation length without restriction, including multiples of four. + +For example: [Pine Scriptยฎ](https://tradingview.com/pine-script-docs) Copied -`plot( -series = close, -title = "Close", -color = color.blue, -show_last = 10 +`//@version=6 +indicator("Line wrapping demo") + +// A wrapped line that is *not* enclosed in parentheses can use any indentation +// length *except* a multiple of four. +float closeDiff = close + - close[1] + +// A wrapped line that *is* enclosed in parentheses *can* use four-space indentation. +float percentChange = ( + closeDiff + / close[1] * 100 +) + +plot( + percentChange, + title = "Percent change", + color = percentChange >= 0 ? color.green : color.red, + linewidth = 8 ) ` +It is possible to mix several wrapping styles in the same script, but keeping a consistent approach within the same file usually makes the code easier to scan and maintain. + ## [Vertical alignment](https://www.tradingview.com/pine-script-docs/writing/style-guide/#vertical-alignment) Vertical alignment using tabs or spaces can be useful in code sections containing many similar lines such as constant declarations or inputs. They can make mass edits much easier using the Pine Editorโ€™s multi-cursor feature (`ctrl` + `alt` + `๐Ÿ …`): From cf22d0a7eb5c53b39f498fc80fae673731817767 Mon Sep 17 00:00:00 2001 From: Jabez Vettriselvan <37698296+jabez4jc@users.noreply.github.com> Date: Fri, 17 Apr 2026 11:24:03 +0530 Subject: [PATCH 2/4] Update README.md --- README.md | 40 ++++++++++++++++++++-------------------- 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/README.md b/README.md index f44cbd3..1e9e77b 100644 --- a/README.md +++ b/README.md @@ -32,14 +32,14 @@ The official documentation is massive. Feeding the entire raw documentation into If you use AI-native editors like Cursor or Windsurf: 1. Clone this repository locally. 2. In your chat interface, reference specific documentation based on what you are building. - * *Building an indicator?* Reference [@functions/ta.md](https://github.com/codenamedevan/pinescriptv6/blob/main/reference/functions/ta.md) and [@functions/drawing.md](https://github.com/codenamedevan/pinescriptv6/blob/main/reference/functions/drawing.md). - * *Building a strategy?* Reference [@functions/strategy.md](https://github.com/codenamedevan/pinescriptv6/blob/main/reference/functions/strategy.md). + * *Building an indicator?* Reference [@functions/ta.md](https://github.com/jabez4jc/pinescriptv6/blob/main/reference/functions/ta.md) and [@functions/drawing.md](https://github.com/jabez4jc/pinescriptv6/blob/main/reference/functions/drawing.md). + * *Building a strategy?* Reference [@functions/strategy.md](https://github.com/jabez4jc/pinescriptv6/blob/main/reference/functions/strategy.md). * *Getting errors?* Reference @concepts/common_errors.md. ### Option 2: Claude Projects / Custom GPTs 1. Download this repository as a ZIP. 2. Upload the relevant files to your **[Claude Project Knowledge](https://support.claude.com/en/articles/9517075-what-are-projects)** ([YouTube Help Here](https://www.youtube.com/watch?v=GJ5jTgcbRHA)) or **[Custom GPT Knowledge](https://help.openai.com/en/articles/8843948-knowledge-in-gpts)**. -3. *Recommendation:* Upload [LLM_MANIFEST.md](https://github.com/codenamedevan/pinescriptv6/blob/main/LLM_MANIFEST.md) and the specific [reference/](https://github.com/codenamedevan/pinescriptv6/tree/main/reference) folders you use most often. +3. *Recommendation:* Upload [LLM_MANIFEST.md](https://github.com/jabez4jc/pinescriptv6/blob/main/LLM_MANIFEST.md) and the specific [reference/](https://github.com/jabez4jc/pinescriptv6/tree/main/reference) folders you use most often. --- @@ -47,11 +47,11 @@ If you use AI-native editors like Cursor or Windsurf: **If you are an LLM or AI Assistant reading this file, follow these instructions:** -1. **Entry Point:** Always check [LLM_MANIFEST.md](https://github.com/codenamedevan/pinescriptv6/blob/main/LLM_MANIFEST.md) first. It acts as the map for this repository. +1. **Entry Point:** Always check [LLM_MANIFEST.md](https://github.com/jabez4jc/pinescriptv6/blob/main/LLM_MANIFEST.md) first. It acts as the map for this repository. 2. **Modular Retrieval:** Do not attempt to ingest the entire codebase at once. - * If the user asks about **Functions** (e.g., RSI, EMA), look in [reference/functions/ta.md](https://github.com/codenamedevan/pinescriptv6/blob/main/reference/functions/ta.md). - * If the user asks about **Backtesting**, look in [reference/functions/strategy.md](https://github.com/codenamedevan/pinescriptv6/blob/main/reference/functions/strategy.md). - * If the user asks about **Arrays or Matrices**, look in [reference/functions/collections.md](https://github.com/codenamedevan/pinescriptv6/blob/main/reference/functions/collections.md). + * If the user asks about **Functions** (e.g., RSI, EMA), look in [reference/functions/ta.md](https://github.com/jabez4jc/pinescriptv6/blob/main/reference/functions/ta.md). + * If the user asks about **Backtesting**, look in [reference/functions/strategy.md](https://github.com/jabez4jc/pinescriptv6/blob/main/reference/functions/strategy.md). + * If the user asks about **Arrays or Matrices**, look in [reference/functions/collections.md](https://github.com/jabez4jc/pinescriptv6/blob/main/reference/functions/collections.md). 3. **Syntax Version:** Enforce //@version=6 in all code generation. 4. **No Hallucinations:** If a function is not found in these files, it likely does not exist in v6 or has been renamed. Do not invent syntax. @@ -59,16 +59,16 @@ If you use AI-native editors like Cursor or Windsurf: ## ๐Ÿ“‚ Repository Structure -* **[LLM_MANIFEST.md](https://github.com/codenamedevan/pinescriptv6/blob/main/LLM_MANIFEST.md)**: The master index. Start here. -* **[concepts/](https://github.com/codenamedevan/pinescriptv6/tree/main/concepts)**: Explanations of how the Pine engine works (Execution model, Timeframes). -* **[reference/](https://github.com/codenamedevan/pinescriptv6/tree/main/reference)**: The strict API dictionary. - * [variables.md](https://github.com/codenamedevan/pinescriptv6/blob/main/reference/variables.md): Built-ins (`open`, `close`, `syminfo`). - * [constants.md](https://github.com/codenamedevan/pinescriptv6/blob/main/reference/constants.md): Fixed values (`color.red`). - * [functions/](https://github.com/codenamedevan/pinescriptv6/tree/main/reference/functions): - * [ta.md](https://github.com/codenamedevan/pinescriptv6/blob/main/reference/functions/ta.md): Technical Analysis. - * [strategy.md](https://github.com/codenamedevan/pinescriptv6/blob/main/reference/functions/strategy.md): Backtesting. - * [request.md](https://github.com/codenamedevan/pinescriptv6/blob/main/reference/functions/request.md): External data. - * [drawing.md](https://github.com/codenamedevan/pinescriptv6/blob/main/reference/functions/drawing.md): Visuals (`plot`, `line`, `box`). +* **[LLM_MANIFEST.md](https://github.com/jabez4jc/pinescriptv6/blob/main/LLM_MANIFEST.md)**: The master index. Start here. +* **[concepts/](https://github.com/jabez4jc/pinescriptv6/tree/main/concepts)**: Explanations of how the Pine engine works (Execution model, Timeframes). +* **[reference/](https://github.com/jabez4jc/pinescriptv6/tree/main/reference)**: The strict API dictionary. + * [variables.md](https://github.com/jabez4jc/pinescriptv6/blob/main/reference/variables.md): Built-ins (`open`, `close`, `syminfo`). + * [constants.md](https://github.com/jabez4jc/pinescriptv6/blob/main/reference/constants.md): Fixed values (`color.red`). + * [functions/](https://github.com/jabez4jc/pinescriptv6/tree/main/reference/functions): + * [ta.md](https://github.com/jabez4jc/pinescriptv6/blob/main/reference/functions/ta.md): Technical Analysis. + * [strategy.md](https://github.com/jabez4jc/pinescriptv6/blob/main/reference/functions/strategy.md): Backtesting. + * [request.md](https://github.com/jabez4jc/pinescriptv6/blob/main/reference/functions/request.md): External data. + * [drawing.md](https://github.com/jabez4jc/pinescriptv6/blob/main/reference/functions/drawing.md): Visuals (`plot`, `line`, `box`). --- @@ -78,11 +78,11 @@ If you are building a Custom GPT or setting up a Project, use this prompt: > You are an expert Pine Script v6 Developer. You have access to a reference library structured into specific folders. > -> 1. When I ask for code, ALWAYS consult the [LLM_MANIFEST.md](https://github.com/codenamedevan/pinescriptv6/blob/main/LLM_MANIFEST.md) to locate the correct reference file. +> 1. When I ask for code, ALWAYS consult the [LLM_MANIFEST.md](https://github.com/jabez4jc/pinescriptv6/blob/main/LLM_MANIFEST.md) to locate the correct reference file. > 2. Prefer `ta.*` namespace functions over manual calculations. > 3. Ensure all scripts start with `//@version=6`. -> 4. If I ask for a Strategy, strictly check [reference/functions/strategy.md](https://github.com/codenamedevan/pinescriptv6/blob/main/reference/functions/strategy.md) for the latest order placement syntax. -> 5. If I ask for complex visuals, check [reference/functions/drawing.md](https://github.com/codenamedevan/pinescriptv6/blob/main/reference/functions/drawing.md) for `polyline` and `box` capabilities. +> 4. If I ask for a Strategy, strictly check [reference/functions/strategy.md](https://github.com/jabez4jc/pinescriptv6/blob/main/reference/functions/strategy.md) for the latest order placement syntax. +> 5. If I ask for complex visuals, check [reference/functions/drawing.md](https://github.com/jabez4jc/pinescriptv6/blob/main/reference/functions/drawing.md) for `polyline` and `box` capabilities. --- From 347474e59fe40c01eb3e98a6c81545f463efe2d9 Mon Sep 17 00:00:00 2001 From: Jabez Vettriselvan <37698296+jabez4jc@users.noreply.github.com> Date: Fri, 17 Apr 2026 11:59:59 +0530 Subject: [PATCH 3/4] Update LLM_MANIFEST with publishing guidelines routing Added new routing entries for publishing guidelines and BBCode. --- LLM_MANIFEST.md | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/LLM_MANIFEST.md b/LLM_MANIFEST.md index 762f741..0caa8bb 100644 --- a/LLM_MANIFEST.md +++ b/LLM_MANIFEST.md @@ -14,6 +14,41 @@ * **Content:** Chronological summary of recent Pine Script v6 additions and behavior changes. * **Keywords:** `request.footprint`, `volume_row`, `syminfo.isin`, `timeframe_bars_back`, `line wrapping`. +## 0.5. Publishing Guidelines + +*Use this file when the user asks about publishing, house rules, visibility types, +formatting tags, paid scripts, or vendor requirements.* + +* **`writing_scripts/publishing_guidelines.md`** + * **Content:** House rules compliance checklists; privacy types (public/private); + visibility types (open/protected/invite-only); vendor requirements for paid scripts; + publication type decision tree; full BBCode formatting reference with usage examples + for every supported tag; unsupported tag list; per-section formatting patterns; + and LLM behaviour rules. + * **Keywords:** `publish`, `house rules`, `open-source`, `protected`, `invite-only`, + `private`, `paid script`, `vendor`, `Script Publishing Rules`, `Vendor Requirements`, + `Editors' picks`, `MPL 2.0`, `15 minutes`, `BBCode`, `[b]`, `[i]`, `[list]`, + `[pine]`, `[url]`, `[image]`, `[quote]`, `[s]`, `$SYMBOL`, `formatting`, `markup`, + `performance claims`, `compliance`, `description`, `release notes`. + +--- +### NEW ROUTING ENTRIES (add to the "## Routing Logic for LLMs" section): + +* **IF** user asks about publishing, visibility types, or house rules: + + retrieve `writing_scripts/publishing_guidelines.md` + +* **IF** user asks about BBCode, description formatting, or markup tags: + + retrieve `writing_scripts/publishing_guidelines.md` (Section 7 โ€” Formatting Reference) + +* **IF** user asks whether they can charge for or sell a script: + + retrieve `writing_scripts/publishing_guidelines.md` (Section 4 โ€” Vendor Requirements) + +* **IF** user asks about the difference between protected vs invite-only vs open-source: + + retrieve `writing_scripts/publishing_guidelines.md` (Section 2 โ€” Visibility Types) + +* **IF** user asks how to format release notes or update an existing script: + + retrieve `writing_scripts/publishing_guidelines.md` (Section 6 โ€” Publication Workflow) + ## 1. Syntax and Core Concepts *Use these files when the user asks about language mechanics, execution flow, or type errors.* From 6104e110d4fd656225d3f7800a858398991a37ab Mon Sep 17 00:00:00 2001 From: Jabez Vettriselvan <37698296+jabez4jc@users.noreply.github.com> Date: Fri, 17 Apr 2026 12:01:04 +0530 Subject: [PATCH 4/4] Create publishing guidelines for Pine Script v6 Added comprehensive publishing guidelines for Pine Script v6, covering privacy types, visibility types, house rules, vendor requirements, and description formatting. --- writing_scripts/publishing_guidelines.md | 423 +++++++++++++++++++++++ 1 file changed, 423 insertions(+) create mode 100644 writing_scripts/publishing_guidelines.md diff --git a/writing_scripts/publishing_guidelines.md b/writing_scripts/publishing_guidelines.md new file mode 100644 index 0000000..6214296 --- /dev/null +++ b/writing_scripts/publishing_guidelines.md @@ -0,0 +1,423 @@ +# Pine Script v6 โ€” Publishing Guidelines + +**Purpose:** Authoritative guidance for LLMs generating, reviewing, or documenting +Pine Script publications. Covers house rules, compliance, publication types, and the +complete description formatting reference. + +**LLM Routing:** Retrieve this file whenever the user asks about: +- Publishing a script (public, private, protected, invite-only, or paid) +- House rules, Script Publishing Rules, or Vendor Requirements +- Choosing a visibility or privacy type +- Description formatting, BBCode tags, or markup syntax +- Whether they can charge for a script +- Release notes format or update workflow + +--- + +## 1. Privacy Types โ€” Public vs Private + +Privacy type controls **discoverability**. Set once at publish time and **cannot be changed**. + +| Privacy | Discoverable? | Editable after publish? | Moderator review? | +|---------|--------------|------------------------|-------------------| +| **Public** | Yes โ€” Community Scripts feed, search, profile | 15 minutes only | Yes | +| **Private** | No โ€” URL access only | Always | No (while private) | + +### Public + +- Appears in the Community Scripts feed and all TradingView search surfaces. +- Script moderators review against House Rules and Script Publishing Rules. +- If non-compliant, the publication becomes **hidden** and the author is notified. +- Authors have **exactly 15 minutes** to edit or delete after publishing. After that the + publication is final and cannot be changed or removed. +- **Recommended:** Always publish a private draft first to validate all content. + +### Private + +- Not visible in Community Scripts. Accessible only via direct URL. +- Always editable and deletable by the author โ€” ideal for drafts. +- **Critical:** Private scripts are strictly for private use. Linking to private scripts + in public TradingView content, social networks, or any public channel means the script + is no longer considered private under TradingView rules. +- Selling access to private scripts is **prohibited**. + +--- + +## 2. Visibility Types โ€” Open, Protected, Invite-Only + +Visibility type controls **who can see the source code and use the script**. Set once at +publish time and **cannot be changed**. + +| Visibility | Source code viewable? | Who can use it? | Plan required | Can charge? | +|------------|----------------------|-----------------|---------------|-------------| +| **Open** | Anyone | Anyone | Any | No | +| **Protected** | Author only | Anyone | Paid plan | No | +| **Invite-only** | Author only | Invited users only | Premium+ | Yes (public only) | + +### Open (Open-Source) + +- Source code visible to any user on the script page and in the Pine Editor (read-only). +- Default licence: **Mozilla Public License 2.0**. Authors may specify an alternative. +- Reuse rules โ€” all three must be met: + - Credit the original author explicitly in the description and code. + - Make **meaningful improvements** โ€” near-identical copies will be hidden. + - Publish reused code open-source unless the original author grants explicit written + permission to go closed-source. +- Eligible for **Editors' Picks** (original, valuable, well-documented, compliant). +- **Always free.** Authors cannot charge for open-source scripts. + +### Protected (Closed-Source, Free) + +- Source code hidden from all users except the author. +- Any user can add and use the script freely. +- Requires a **paid TradingView plan** to publish. +- Description **must** explain what unique qualities justify protecting the code. + Protected scripts that replicate open-source behaviour will be hidden. +- **Always free.** Authors cannot charge for protected scripts. + +### Invite-Only (Closed-Source, Access-Controlled) + +- Source code hidden; only **explicitly invited** users can add the script to their chart. +- Requires a **Premium or higher TradingView plan** to publish. +- Authors selling access are classified as **vendors** (see Section 4). +- The **"Author's instructions"** field is mandatory โ€” must contain how users request access. +- **Only public invite-only scripts can be sold.** Private scripts cannot be sold. + +--- + +## 3. House Rules & Compliance Checklist + +Applies to **all** public script publications. Verify every item before generating or +approving a description. + +### Pre-Publish Checklist + +- [ ] Description begins in **English** (other languages may follow) +- [ ] Title uses **standard ASCII only** โ€” no emoji, no ALL CAPS words + (abbreviations are fine: RSI, EMA, VWAP, ATR, POC, RMA) +- [ ] **Zero performance claims** without substantiation โ€” no "90% win rate", + "guaranteed profit", "never loses", etc. +- [ ] No external links, social handles, or promotional content in the **title** +- [ ] Chart shows **only what is necessary** โ€” no extra indicators, no drawing clutter +- [ ] Source code is open-source (MPL 2.0) unless protected/invite-only is justified +- [ ] No copying or paraphrasing another publication without explicit credit +- [ ] Closed-source descriptions explain **why the code requires protection** +- [ ] No unsubstantiated statements about capabilities or profitability + +### Originality Requirements + +- Publish only scripts that are **original** and provide genuine community value. +- Do not publish scripts that rehash, mimic, or copy existing public scripts. +- Do not publish scripts that combine indicators without a clear, unique purpose. + +### Description Content Requirements + +- Cover: purpose, how it works, how to use it, why it is original. +- For closed-source: explain unique qualities that justify hiding the code. +- Emoji and non-ASCII characters: use sparingly. Avoid all-caps prose. +- Unsubstantiated performance claims โ†’ script hidden by moderators. + +### Chart Requirements + +- Chart must demonstrate this script's outputs clearly. +- Remove **all** unnecessary indicators and drawing tools before publishing. +- The chart is not for showcasing complex multi-indicator setups. + +--- + +## 4. Vendor Requirements (Invite-Only / Paid Scripts) + +Authors who sell access to invite-only scripts are **vendors** and must comply with both +House Rules and Vendor Requirements. + +- **Only public invite-only scripts can be sold.** No other type. +- Private scripts cannot be sold. Open-source and protected scripts are always free. +- TradingView does not process payments. All transactions are strictly between vendor + and user โ€” TradingView has no involvement. +- The "Author's instructions" field must clearly explain how to request and pay for + access (contact details, external purchase link, etc.). +- Vendors are solely responsible for delivery, support, and legal compliance. + +### Vendor Description Requirements + +- Explain what the script does and why its unique value justifies payment. +- No unsubstantiated profitability or performance claims. +- Must begin with an English explanation. +- Must not impersonate TradingView or imply official endorsement. + +--- + +## 5. Publication Type Decision Tree + +``` +Is the script for personal use, drafting, or small-group testing? + โ””โ”€ YES โ†’ Privacy: PRIVATE + Always use private draft workflow before going public. + +Is the script for the full TradingView community? + โ””โ”€ YES โ†’ Privacy: PUBLIC โ†’ then ask: + + Should the source code be visible? + โ”œโ”€ YES โ†’ Visibility: OPEN (open-source, MPL 2.0, free) + โ”‚ Best for: community contribution, Editors' Picks eligibility, + โ”‚ educational scripts, indicator libraries. + โ”‚ + โ””โ”€ NO โ†’ Should anyone be able to use it, or only specific users? + โ”œโ”€ ANYONE โ†’ Visibility: PROTECTED (closed-source, free) + โ”‚ Requires: paid plan. + โ”‚ Must justify in description why code is protected. + โ”‚ + โ””โ”€ SPECIFIC USERS ONLY โ†’ Visibility: INVITE-ONLY (closed-source, gated) + Requires: Premium+ plan. + Can charge users โ€” vendor rules apply. +``` + +--- + +## 6. Publication Workflow + +### For Public Scripts (All Visibility Types) + +1. Write and test the script โ€” no compile errors, behaviour matches description. +2. Clean the chart โ€” remove everything not needed to demonstrate the script. +3. **Publish a private draft** โ€” Privacy: Private. Validate widget, description, chart. + Fix all errors (private scripts are always editable). +4. Copy the validated description text from the private draft's Edit window. +5. Create the **public publication** โ€” paste the verified description. Set correct + visibility. Check the House Rules acknowledgement box. +6. **You have 15 minutes** โ€” verify the live script page immediately. Title and + description are final after 15 minutes. +7. Optionally delete the private draft. + +### For Updates to Existing Public Scripts + +- Push updates via the **script update** flow โ€” do not create a new publication. +- Privacy and visibility types cannot be changed on existing publications. +- Append a Release Notes block **below** the original description (never replace it): + +``` +[b]Release Notes โ€” YYYY-MM-DD[/b] +[list] +[*]Change 1 +[*]Change 2 +[/list] +``` + +--- + +## 7. Description Formatting โ€” BBCode Reference + +TradingView description fields use **BBCode-style markup only**. Markdown, HTML, and +all other formats render as raw literal text and will not format correctly. + +The toolbar in the "Publish script" description field inserts these tags automatically, +but they can also be typed directly. + +### Complete Tag Reference + +| Purpose | Syntax | Notes | +|---------|--------|-------| +| **Bold** | `[b]text[/b]` | Section headings and input parameter names | +| *Italic* | `[i]text[/i]` | Sparingly, for single-word emphasis | +| ~~Strikethrough~~ | `[s]text[/s]` | Release notes for removed/deprecated items | +| Pine code block | `[pine]code[/pine]` | Syntax-highlighted block; always on its own line | +| Bulleted list | `[list][*]item[/list]` | Each item starts with `[*]` on its own line | +| Numbered list | `[list=1][*]item[/list]` | Same structure, `[list=1]` opening tag | +| Block quotation | `[quote]text[/quote]` | Multi-line; for external definitions or citations | +| Hyperlink | `[url=URL]label[/url]` | TradingView/docs links only; no ads | +| Chart image | `[image]URL[/image]` | TradingView snapshot URL only | +| Symbol link | `$EXCHANGE:SYMBOL` | Inline; no tags โ€” `$` prefix creates the link | + +### Tag Usage โ€” Full Detail + +#### Bold `[b][/b]` +The primary structural element. Use for every section heading and for input parameter +names within the Inputs list. +``` +[b]How It Works[/b] + +[b]Inputs[/b] + +[list=1] +[*][b]Lookback Length[/b] โ€” description here. +[/list] +``` + +#### Italic `[i][/i]` +Use sparingly. One or two words per paragraph at most. Overuse reduces impact. +``` +The signal fires only when volume is [i]above[/i] the 20-bar average. +``` + +#### Strikethrough `[s][/s]` +Rarely needed. Use in release notes to show a changed default or a removed feature. +``` +[s]Default: 14[/s] Changed to: 20 +``` + +#### Pine Code Block `[pine][/pine]` +Renders with full Pine Script syntax highlighting. Always start on a new line after +the opening tag. Use for the key calculation only โ€” not the full script. +``` +[pine] +// Delta confirmation using native footprint data +fp = request.footprint(ticksPerRow) +delta = fp.delta(fp) +weakZone := delta > 0 and zoneType == "supply" +[/pine] +``` + +#### Bulleted List `[list][*]...[/list]` +Each bullet item must begin with `[*]` on its own line inside the `[list]` tags. +Use for: colour key, usage tips, feature lists, recommended pairings. +``` +[list] +[*]Green fill โ€” bullish delta confirmation (demand zone confirmed) +[*]Red fill โ€” bearish delta confirmation (supply zone confirmed) +[*]Grey fill โ€” zone not yet confirmed by order flow +[*]50% opacity โ€” weak zone (delta opposes zone type) +[/list] +``` + +#### Numbered List `[list=1][*]...[/list]` +Same structure as the bulleted list. Use `[list=1]` as the opening tag. +Use for: input documentation (always), step-by-step instructions, ordered procedures. +``` +[list=1] +[*][b]Lookback Length[/b] โ€” Bars used to detect pivot highs and lows. Lower (e.g. 5): more zones, more noise. Higher (e.g. 20): fewer, stronger zones. Default: 10. +[*][b]Delta Threshold[/b] โ€” Minimum absolute delta to confirm a zone. 0 accepts any delta; higher values require stronger confirmation. Default: 0. +[*][b]Ticks Per Row[/b] โ€” Price range per footprint row, in ticks. Smaller values give finer granularity; larger values give broader rows. Default: 4. +[/list] +``` + +#### Block Quotation `[quote][/quote]` +Use to cite an external definition or a well-known formula. One per description maximum. +``` +[quote]VWAP is calculated as the cumulative sum of (price ร— volume) divided by cumulative volume over the session.[/quote] +``` + +#### Hyperlink `[url=URL]label[/url]` +Allowed only for links to TradingView pages and official reference materials +(e.g., TradingView Help Center, Pine Script documentation). **Never link to social +media, personal websites, storefronts, or any promotional content** โ€” this violates +House Rules and will result in the publication being hidden. +``` +[url=https://www.tradingview.com/pine-script-docs/concepts/strategies/]Pine Script Strategy Documentation[/url] +``` + +#### Chart Image `[image]URL[/image]` +Renders a chart snapshot inline in the description. URL must be a TradingView snapshot +(`https://www.tradingview.com/x/XXXX/`) or TradingView idea URL. These tags are +optional โ€” snapshot URLs pasted directly into the description also render automatically. +Clean the chart before taking the snapshot, exactly as you would for the publication chart. +``` +[image]https://www.tradingview.com/x/AbCdEfGh/[/image] +``` + +#### Symbol Link `$EXCHANGE:SYMBOL` +The `$` prefix before a valid symbol creates an inline hyperlink to that symbol's +TradingView overview page. No opening/closing tags required. +``` +This indicator is optimised for $CME:ES1!, $CME:NQ1!, and $NASDAQ:AAPL. +``` + +### Tags That Do NOT Work + +These will render as raw text โ€” do not use them: + +| Unsupported | Common mistake | Correct alternative | +|-------------|---------------|---------------------| +| `# Heading` | Markdown habit | `[b]Heading[/b]` | +| `## Heading` | Markdown habit | `[b]Heading[/b]` | +| `**bold**` | Markdown habit | `[b]bold[/b]` | +| `_italic_` or `*italic*` | Markdown habit | `[i]italic[/i]` | +| `` `code` `` | Markdown inline code | Plain text or `[pine]code[/pine]` | +| `---` | Markdown divider | Blank line or new `[b]` heading | +| `bold` | HTML | `[b]bold[/b]` | +| `italic` | HTML | `[i]italic[/i]` | +| Any `` tag | HTML | BBCode equivalent | +| Nested `[list]` inside `[list]` | Attempted sub-lists | Flatten to a single list level | +| `[table]` | Not available | Bulleted list with dashes or plain prose | + +### Recommended Formatting Patterns by Section + +**Title line** (first line of description): +``` +[b]Script Name Here[/b] +``` + +**Overview** โ€” plain prose paragraphs, no lists or code: +``` +[b]Overview[/b] + +One to three paragraphs. Plain language. No lists, no code blocks here. +``` + +**How It Works** โ€” prose, optional code snippet, optional colour key: +``` +[b]How It Works[/b] + +Plain explanation of core logic. + +[pine] +delta = fp.delta(fp) +[/pine] + +Colour coding: +[list] +[*]Green โ€” confirmed demand zone +[*]Red โ€” confirmed supply zone +[/list] +``` + +**Inputs** โ€” always a numbered list with bold parameter names: +``` +[b]Inputs[/b] + +[list=1] +[*][b]Parameter Name[/b] โ€” What it controls. Low: X. High: Y. Default: Z. +[/list] +``` + +**Usage Notes** โ€” always a bulleted list: +``` +[b]Usage Notes[/b] + +[list] +[*]Actionable tip one. +[*]Actionable tip two. +[/list] +``` + +**Release Notes** (updates only) โ€” appended below original description: +``` +[b]Release Notes โ€” YYYY-MM-DD[/b] +[list] +[*]Added: delta threshold input. +[*]Fixed: POC marker rendering on first bar. +[/list] +``` + +--- + +## 8. LLM Behaviour Rules + +When generating or reviewing a publication: + +1. **Identify the publication type first** โ€” open-source community tool, protected + proprietary, paid invite-only, or private draft. Ask if not clear from context. +2. **Apply the correct compliance checklist** โ€” Section 3 for all public scripts; + Section 4 additionally for invite-only/paid. +3. **Use BBCode exclusively** โ€” never output Markdown or HTML in description text. + Every heading uses `[b][/b]`. Every list uses `[list]` or `[list=1]`. +4. **Never generate performance claims** even if the user requests them. Explain why + they violate House Rules and offer to describe what the script measures instead. +5. **For closed-source descriptions** โ€” always include a paragraph explaining the + unique qualities that justify protecting the code. +6. **For invite-only descriptions** โ€” always include a placeholder for the Author's + Instructions field (contact method for access requests). +7. **Recommend the private draft workflow** before any public publication, especially + for first-time authors. +8. **Flag chart guidance** โ€” remind the user to clean the chart. Never describe a + chart with multiple indicators or drawing tools. +9. **Release notes go below the original** โ€” when updating, append; never replace.