[{"data":1,"prerenderedAt":759},["ShallowReactive",2],{"navigation_docs":3,"-guide-agents":148,"-guide-agents-surround":754},[4,40],{"title":5,"path":6,"stem":7,"children":8,"icon":39},"Guide","\u002Fguide","1.guide\u002F01.index",[9,11,15,19,23,27,31,35],{"title":10,"path":6,"stem":7},"Getting Started",{"title":12,"path":13,"stem":14},"Hashing","\u002Fguide\u002Fhashing","1.guide\u002F02.hashing",{"title":16,"path":17,"stem":18},"HMAC and verify","\u002Fguide\u002Fverify","1.guide\u002F03.verify",{"title":20,"path":21,"stem":22},"Salted KDFs","\u002Fguide\u002Fkdf","1.guide\u002F04.kdf",{"title":24,"path":25,"stem":26},"CLI","\u002Fguide\u002Fcli","1.guide\u002F05.cli",{"title":28,"path":29,"stem":30},"Agents","\u002Fguide\u002Fagents","1.guide\u002F06.agents",{"title":32,"path":33,"stem":34},"Custom algorithms","\u002Fguide\u002Fcustom","1.guide\u002F07.custom",{"title":36,"path":37,"stem":38},"Playground","\u002Fguide\u002Fplayground","1.guide\u002F08.playground","i-lucide-book-open",{"title":41,"path":42,"stem":43,"children":44,"icon":147},"Algorithms","\u002Falgorithms","2.algorithms\u002F00.index",[45,47,51,55,59,63,67,71,75,79,83,87,91,95,99,103,107,111,115,119,123,127,131,135,139,143],{"title":46,"path":42,"stem":43},"Every algorithm",{"title":48,"path":49,"stem":50},"SHA-256","\u002Falgorithms\u002Fsha256","2.algorithms\u002F01.sha256",{"title":52,"path":53,"stem":54},"SHA-384","\u002Falgorithms\u002Fsha384","2.algorithms\u002F02.sha384",{"title":56,"path":57,"stem":58},"SHA-512","\u002Falgorithms\u002Fsha512","2.algorithms\u002F03.sha512",{"title":60,"path":61,"stem":62},"SHA-512Half","\u002Falgorithms\u002Fsha512-half","2.algorithms\u002F04.sha512-half",{"title":64,"path":65,"stem":66},"SHA3-256","\u002Falgorithms\u002Fsha3-256","2.algorithms\u002F05.sha3-256",{"title":68,"path":69,"stem":70},"SHA3-512","\u002Falgorithms\u002Fsha3-512","2.algorithms\u002F06.sha3-512",{"title":72,"path":73,"stem":74},"Keccak-256","\u002Falgorithms\u002Fkeccak256","2.algorithms\u002F07.keccak256",{"title":76,"path":77,"stem":78},"BLAKE2b","\u002Falgorithms\u002Fblake2b","2.algorithms\u002F08.blake2b",{"title":80,"path":81,"stem":82},"BLAKE2b-256","\u002Falgorithms\u002Fblake2b-256","2.algorithms\u002F09.blake2b-256",{"title":84,"path":85,"stem":86},"BLAKE2b-224","\u002Falgorithms\u002Fblake2b-224","2.algorithms\u002F10.blake2b-224",{"title":88,"path":89,"stem":90},"BLAKE2s","\u002Falgorithms\u002Fblake2s","2.algorithms\u002F11.blake2s",{"title":92,"path":93,"stem":94},"BLAKE3","\u002Falgorithms\u002Fblake3","2.algorithms\u002F12.blake3",{"title":96,"path":97,"stem":98},"BLAKE-256","\u002Falgorithms\u002Fblake256","2.algorithms\u002F13.blake256",{"title":100,"path":101,"stem":102},"RIPEMD-160","\u002Falgorithms\u002Fripemd160","2.algorithms\u002F14.ripemd160",{"title":104,"path":105,"stem":106},"HASH160","\u002Falgorithms\u002Fhash160","2.algorithms\u002F15.hash160",{"title":108,"path":109,"stem":110},"HASH256","\u002Falgorithms\u002Fhash256","2.algorithms\u002F16.hash256",{"title":112,"path":113,"stem":114},"MD5","\u002Falgorithms\u002Fmd5","2.algorithms\u002F17.md5",{"title":116,"path":117,"stem":118},"SHA-1","\u002Falgorithms\u002Fsha1","2.algorithms\u002F18.sha1",{"title":120,"path":121,"stem":122},"SHA-0","\u002Falgorithms\u002Fsha0","2.algorithms\u002F19.sha0",{"title":124,"path":125,"stem":126},"CRC-32","\u002Falgorithms\u002Fcrc32","2.algorithms\u002F20.crc32",{"title":128,"path":129,"stem":130},"CRC-16\u002FXMODEM","\u002Falgorithms\u002Fcrc16-xmodem","2.algorithms\u002F21.crc16-xmodem",{"title":132,"path":133,"stem":134},"xxHash (XXH64)","\u002Falgorithms\u002Fxxhash","2.algorithms\u002F22.xxhash",{"title":136,"path":137,"stem":138},"FNV-1a (64-bit)","\u002Falgorithms\u002Ffnv1a","2.algorithms\u002F23.fnv1a",{"title":140,"path":141,"stem":142},"scrypt","\u002Falgorithms\u002Fscrypt","2.algorithms\u002F24.scrypt",{"title":144,"path":145,"stem":146},"PBKDF2","\u002Falgorithms\u002Fpbkdf2","2.algorithms\u002F25.pbkdf2","i-lucide-library",{"id":149,"title":28,"body":150,"description":747,"extension":748,"links":749,"meta":750,"navigation":682,"path":29,"seo":752,"stem":30,"__hash__":753},"docs\u002F1.guide\u002F06.agents.md",{"type":151,"value":152,"toc":738},"minimark",[153,158,181,307,341,345,348,358,364,370,389,393,420,425,429,432,438,445,454,458,513,516,591,598,602,628,635,639,724,734],[154,155,157],"h2",{"id":156},"same-tools-every-host","Same tools, every host",[159,160,161,162,166,167,170,171,174,175,180],"p",{},"The MCP server, the Pi and OMP extensions and the AI SDK tools in ",[163,164,165],"code",{},"@agntn\u002Fhashes\u002Fai"," all call the executors in ",[163,168,169],{},"src\u002Ftool-operations.ts",". Same arguments, same checks, same text back, and a fix lands once. This site runs those executors too, so the ",[163,172,173],{},"Full tool response"," dialogs on the landing and in the ",[176,177,179],"a",{"href":178},"\u002Fplayground","playground"," are exactly what a model reads.",[182,183,184,200],"table",{},[185,186,187],"thead",{},[188,189,190,194,197],"tr",{},[191,192,193],"th",{},"Tool",[191,195,196],{},"Does",[191,198,199],{},"Arguments",[201,202,203,235,261,288],"tbody",{},[188,204,205,211,214],{},[206,207,208],"td",{},[163,209,210],{},"hash_compute",[206,212,213],{},"Digest of text or bytes",[206,215,216,219,220,219,223,219,226,219,229,219,232],{},[163,217,218],{},"algorithm",", ",[163,221,222],{},"input",[163,224,225],{},"inputEncoding",[163,227,228],{},"encoding",[163,230,231],{},"salt",[163,233,234],{},"parameters",[188,236,237,242,245],{},[206,238,239],{},[163,240,241],{},"hash_hmac",[206,243,244],{},"HMAC with a key",[206,246,247,219,249,219,251,219,253,219,256,219,259],{},[163,248,218],{},[163,250,222],{},[163,252,225],{},[163,254,255],{},"key",[163,257,258],{},"keyEncoding",[163,260,228],{},[188,262,263,268,271],{},[206,264,265],{},[163,266,267],{},"hash_verify",[206,269,270],{},"Compare with an expected digest",[206,272,273,219,275,219,277,219,279,219,282,219,284,219,286],{},[163,274,218],{},[163,276,222],{},[163,278,225],{},[163,280,281],{},"expected",[163,283,228],{},[163,285,231],{},[163,287,234],{},[188,289,290,295,298],{},[206,291,292],{},[163,293,294],{},"hash_algorithms",[206,296,297],{},"The list, one family, or one algorithm's options",[206,299,300,303,304,306],{},[163,301,302],{},"family"," or ",[163,305,218],{},", both optional",[159,308,309,311,312,315,316,219,319,219,322,324,325,328,329,219,332,324,335,337,338,340],{},[163,310,234],{}," carries what an algorithm declares beyond encoding, key and salt: ",[163,313,314],{},"seed"," for xxHash, ",[163,317,318],{},"N",[163,320,321],{},"r",[163,323,159],{}," and ",[163,326,327],{},"keyLength"," for scrypt, ",[163,330,331],{},"iterations",[163,333,334],{},"digest",[163,336,327],{}," for PBKDF2. A model that isn't sure calls ",[163,339,294],{}," with the name first. The descriptions say so, because otherwise models guess.",[154,342,344],{"id":343},"what-a-model-reads","What a model reads",[159,346,347],{},"Two lines. The digest, then what it is:",[349,350,356],"pre",{"className":351,"code":353,"language":354,"meta":355},[352],"language-text","751e76e8199196d454941c45d1b3a323f1433bd6\nhash160, hex, 20 bytes\n","text","",[163,357,353],{"__ignoreMap":355},[159,359,360,361,363],{},"For a KDF the second line also carries the salt and every cost, since an MCP client sees only this text and the next ",[163,362,267],{}," needs all of it:",[349,365,368],{"className":366,"code":367,"language":354,"meta":355},[352],"c5e478d59288c841aa530db6845c4c8d962893a001ce4e11a4963873aa98134a\npbkdf2, hex, 32 bytes, iterations 4096, digest sha256, keyLength 32, salt 73616c74\n",[163,369,367],{"__ignoreMap":355},[159,371,372,374,375,303,378,381,382,384,385,388],{},[163,373,267],{}," answers ",[163,376,377],{},"MATCH",[163,379,380],{},"MISMATCH"," with both digests. ",[163,383,294],{}," lists one line per algorithm, family, size and HMAC support included. The Pi and OMP extensions and the AI SDK also hand the host structured ",[163,386,387],{},"details"," next to the text.",[154,390,392],{"id":391},"bytes-not-letters","Bytes, not letters",[159,394,395,397,398,401,402,324,405,408,409,412,413,415,416,419],{},[163,396,225],{}," is ",[163,399,400],{},"utf8"," by default. ",[163,403,404],{},"hex",[163,406,407],{},"base64"," hash the bytes they spell, which is what you want for a public key, a raw transaction or a script. Without it, ",[163,410,411],{},"hash160"," of a public key hashes 66 characters of text and answers with a perfectly valid digest of the wrong thing. ",[163,414,404],{}," takes no ",[163,417,418],{},"0x"," prefix.",[159,421,422,424],{},[163,423,258],{}," does the same for an HMAC key. A BIP32 chain code keys the HMAC as 32 bytes, not as 64 letters.",[154,426,428],{"id":427},"what-they-refuse","What they refuse",[159,430,431],{},"Every schema is closed. A misspelled argument is an error, not a quiet default:",[349,433,436],{"className":434,"code":435,"language":354,"meta":355},[352],"Invalid option salt_hex=(unknown): hash_compute takes only algorithm, input, inputEncoding, encoding, salt, parameters\n",[163,437,435],{"__ignoreMap":355},[159,439,440,441,444],{},"That one matters. Dropping ",[163,442,443],{},"salt_hex"," would have hashed with a fresh random salt and a model would never know why its digest doesn't reproduce.",[159,446,447,448,450,451,453],{},"The bounds sit in the schema and are checked again in the executor, because a host is free to skip schema validation. Input up to a million characters, key up to ten thousand, a salt of 1 to 256 bytes in hex, at most eight ",[163,449,234],{},". KDF costs are capped too, ",[176,452,20],{"href":21}," has the numbers. Nothing is written anywhere and there's no network to reach.",[154,455,457],{"id":456},"mcp","MCP",[349,459,463],{"className":460,"code":461,"language":462,"meta":355,"style":355},"language-bash shiki shiki-themes hashes hashes hashes","hashes mcp\nclaude mcp add hashes --scope user -- npx -y @agntn\u002Fhashes mcp\n","bash",[163,464,465,478],{"__ignoreMap":355},[466,467,470,474],"span",{"class":468,"line":469},"line",1,[466,471,473],{"class":472},"sK71F","hashes",[466,475,477],{"class":476},"shU9J"," mcp\n",[466,479,481,484,487,490,493,496,499,502,505,508,511],{"class":468,"line":480},2,[466,482,483],{"class":472},"claude",[466,485,486],{"class":476}," mcp",[466,488,489],{"class":476}," add",[466,491,492],{"class":476}," hashes",[466,494,495],{"class":476}," --scope",[466,497,498],{"class":476}," user",[466,500,501],{"class":476}," --",[466,503,504],{"class":476}," npx",[466,506,507],{"class":476}," -y",[466,509,510],{"class":476}," @agntn\u002Fhashes",[466,512,477],{"class":476},[159,514,515],{},"Or in a client's config:",[349,517,521],{"className":518,"code":519,"language":520,"meta":355,"style":355},"language-json shiki shiki-themes hashes hashes hashes","{\n  \"mcpServers\": {\n    \"hashes\": { \"command\": \"npx\", \"args\": [\"-y\", \"@agntn\u002Fhashes\", \"mcp\"] }\n  }\n}\n","json",[163,522,523,529,537,579,585],{"__ignoreMap":355},[466,524,525],{"class":468,"line":469},[466,526,528],{"class":527},"s38Sx","{\n",[466,530,531,534],{"class":468,"line":480},[466,532,533],{"class":472},"  \"mcpServers\"",[466,535,536],{"class":527},": {\n",[466,538,540,543,546,549,552,555,557,560,563,566,568,571,573,576],{"class":468,"line":539},3,[466,541,542],{"class":472},"    \"hashes\"",[466,544,545],{"class":527},": { ",[466,547,548],{"class":472},"\"command\"",[466,550,551],{"class":527},": ",[466,553,554],{"class":476},"\"npx\"",[466,556,219],{"class":527},[466,558,559],{"class":472},"\"args\"",[466,561,562],{"class":527},": [",[466,564,565],{"class":476},"\"-y\"",[466,567,219],{"class":527},[466,569,570],{"class":476},"\"@agntn\u002Fhashes\"",[466,572,219],{"class":527},[466,574,575],{"class":476},"\"mcp\"",[466,577,578],{"class":527},"] }\n",[466,580,582],{"class":468,"line":581},4,[466,583,584],{"class":527},"  }\n",[466,586,588],{"class":468,"line":587},5,[466,589,590],{"class":527},"}\n",[159,592,593,594,597],{},"stdio, every tool read-only and idempotent. A call that fails the schema or throws a ",[163,595,596],{},"HashError"," comes back as a tool error with the reason, and the session carries on.",[154,599,601],{"id":600},"pi-and-omp","Pi and OMP",[349,603,605],{"className":460,"code":604,"language":462,"meta":355,"style":355},"pi install npm:@agntn\u002Fhashes\nomp install @agntn\u002Fhashes\n",[163,606,607,618],{"__ignoreMap":355},[466,608,609,612,615],{"class":468,"line":469},[466,610,611],{"class":472},"pi",[466,613,614],{"class":476}," install",[466,616,617],{"class":476}," npm:@agntn\u002Fhashes\n",[466,619,620,623,625],{"class":468,"line":480},[466,621,622],{"class":472},"omp",[466,624,614],{"class":476},[466,626,627],{"class":476}," @agntn\u002Fhashes\n",[159,629,630,631,634],{},"Both extensions are declared in ",[163,632,633],{},"package.json"," and ship as source the host loads directly.",[154,636,638],{"id":637},"ai-sdk","AI SDK",[349,640,644],{"className":641,"code":642,"language":643,"meta":355,"style":355},"language-ts shiki shiki-themes hashes hashes hashes","import { generateText } from \"ai\";\nimport { hashTools } from \"@agntn\u002Fhashes\u002Fai\";\n\nawait generateText({\n  model,\n  tools: hashTools,\n  prompt: \"What's the HASH160 of 0279be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798?\",\n});\n","ts",[163,645,646,664,678,684,695,700,706,718],{"__ignoreMap":355},[466,647,648,652,655,658,661],{"class":468,"line":469},[466,649,651],{"class":650},"skH_V","import",[466,653,654],{"class":527}," { generateText } ",[466,656,657],{"class":650},"from",[466,659,660],{"class":476}," \"ai\"",[466,662,663],{"class":527},";\n",[466,665,666,668,671,673,676],{"class":468,"line":480},[466,667,651],{"class":650},[466,669,670],{"class":527}," { hashTools } ",[466,672,657],{"class":650},[466,674,675],{"class":476}," \"@agntn\u002Fhashes\u002Fai\"",[466,677,663],{"class":527},[466,679,680],{"class":468,"line":539},[466,681,683],{"emptyLinePlaceholder":682},true,"\n",[466,685,686,689,692],{"class":468,"line":581},[466,687,688],{"class":650},"await",[466,690,691],{"class":472}," generateText",[466,693,694],{"class":527},"({\n",[466,696,697],{"class":468,"line":587},[466,698,699],{"class":527},"  model,\n",[466,701,703],{"class":468,"line":702},6,[466,704,705],{"class":527},"  tools: hashTools,\n",[466,707,709,712,715],{"class":468,"line":708},7,[466,710,711],{"class":527},"  prompt: ",[466,713,714],{"class":476},"\"What's the HASH160 of 0279be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798?\"",[466,716,717],{"class":527},",\n",[466,719,721],{"class":468,"line":720},8,[466,722,723],{"class":527},"});\n",[159,725,726,729,730,733],{},[163,727,728],{},"hashTools"," holds all of them under the same names. Each one is also exported alone, ",[163,731,732],{},"hashComputeTool"," and friends, if you want to hand a model fewer.",[735,736,737],"style",{},"html pre.shiki code .sK71F, html code.shiki .sK71F{--shiki-light:var(--shiki-token-function);--shiki-default:var(--shiki-token-function);--shiki-dark:var(--shiki-token-function)}html pre.shiki code .shU9J, html code.shiki .shU9J{--shiki-light:var(--shiki-token-string);--shiki-default:var(--shiki-token-string);--shiki-dark:var(--shiki-token-string)}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html pre.shiki code .skH_V, html code.shiki .skH_V{--shiki-light:var(--shiki-token-keyword);--shiki-default:var(--shiki-token-keyword);--shiki-dark:var(--shiki-token-keyword)}html pre.shiki code .s38Sx, html code.shiki .s38Sx{--shiki-light:var(--ui-text-highlighted);--shiki-default:var(--ui-text-highlighted);--shiki-dark:var(--ui-text-highlighted)}",{"title":355,"searchDepth":480,"depth":480,"links":739},[740,741,742,743,744,745,746],{"id":156,"depth":480,"text":157},{"id":343,"depth":480,"text":344},{"id":391,"depth":480,"text":392},{"id":427,"depth":480,"text":428},{"id":456,"depth":480,"text":457},{"id":600,"depth":480,"text":601},{"id":637,"depth":480,"text":638},"The same hash tools over MCP and Pi and OMP and the AI SDK. What they take and what they refuse and what the model reads back","md",null,{"icon":751},"i-lucide-bot",{"title":28,"description":747},"Osa_C6Z5iy5ETwjFE4_0usunDuwPn4lowG2PuYOwIoY",[755,757],{"title":24,"path":25,"stem":26,"description":756,"children":-1},"The hashes command. Hash and HMAC and verify from a shell or stdin with the digest alone on stdout",{"title":32,"path":33,"stem":34,"description":758,"children":-1},"Extend FixedHash or BlockHash or Hash and register the class. The CLI and the tools see it too",1790683656173]