Description
Replace just that token and report replaced when replacement differs.
Logical notation distinguishes terms, argument structure, scope, and inference rules. A string formatter or local structural check can organize a supplied expression without proving an argument or determining its truth.
Replace just that token and report replaced when replacement differs.
When to use this tool
Use Identity Substitution Position when you need one bounded logical-notation component or explicit term comparison.
How to use the tool and how it works
- Enter tokens, index, expectedToken, replacementToken. Use the units and conventions below.
- Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
- Read tokens, replaced. Inspect replaced before interpreting the associated values.
Require a valid token index and exact expectedToken match at that position. Replace just that token and report replaced when replacement differs.1
| Input field | Meaning and units | Accepted input |
|---|---|---|
| tokens | Tokens | Required. Array of text; maximum UTF-16 length 8192; maximum items 256. |
| index | Position under the zero-based or one-based convention stated above. | Required. Safe integer; minimum 0. |
| expectedToken | Expected Token | Required. Text; maximum UTF-16 length 8192. |
| replacementToken | Replacement Token | Required. Text; maximum UTF-16 length 8192. |
| Output field | Interpretation | Returned shape |
|---|---|---|
| tokens | Tokens | Required. Array of text; maximum UTF-16 length 8192; maximum items 256. |
| replaced | Replaced | Required. Boolean. |
{
"input": {
"tokens": [
"a",
"=",
"a"
],
"index": 2,
"expectedToken": "a",
"replacementToken": "b"
},
"output": {
"tokens": [
"a",
"=",
"b"
],
"replaced": true
}
} Limitations and assumptions
- This is literal token substitution without parsing, variable binding, capture avoidance, type checking, or logical equivalence guarantees.
- Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.
- Numeric calculations use binary floating point unless exact decimal-integer arithmetic is explicitly stated. No hidden measurement tolerance or decimal rounding is added; nonfinite or out-of-contract results are rejected. Numeric signed-zero results are exported as zero.
Alternative or Complementary methods
Use a parser or proof system for the complete formal language when validity or derivability matters.
References
Similar or alternative tools
- Bound Variable Occurrence Scope Tag
Test whether occurrenceScopeIds contains the binding scope.
- Argument Premise Negation
Require premise to contain nonwhitespace text and return it unchanged inside ¬(premise).