Brunobkr/llama.cpp_AlgMor24_github
ΩFFFΣLLIa • llama.cpp • AlgMor24 ██████╗ ███████╗███████╗███████╗██╗ ██╗ ██╗ █████╗ ██╔═══██╗██╔════╝██╔════╝██╔════╝██║ ██║ ██║██╔══██╗ ██║ ██║█████╗ █████╗ █████╗ ██║ ██║ ██║███████║ ██║ ██║██╔══╝ ██╔══╝ ██╔══╝ ██║ ██║ ██║██╔══██║ ╚██████╔╝██║ ██║ ███████╗███████╗███████╗██║██║ ██║ ╚═════╝ ╚═╝ ╚═╝ ╚══════╝╚══════╝╚══════╝╚═╝╚═╝ ╚═╝ High-Performance LLM / VLM Inference & Autonomous Agentic Ecosystem… See the full description on the dataset page: https://huggingface.co/datasets/Brunobkr/llama.cpp_AlgMor24_github.
03.1k
1# unist-util-is2 3[![Build][build-badge]][build]4[![Coverage][coverage-badge]][coverage]5[![Downloads][downloads-badge]][downloads]6[![Size][size-badge]][size]7[![Sponsors][sponsors-badge]][collective]8[![Backers][backers-badge]][collective]9[![Chat][chat-badge]][chat]10 11[**unist**][unist] utility to check if a node passes a test.12 13## Install14 15[npm][]:16 17```sh18npm install unist-util-is19```20 21## Use22 23```js24var is = require('unist-util-is')25 26var node = {type: 'strong'}27var parent = {type: 'paragraph', children: [node]}28 29function test(node, n) {30 return n === 531}32 33is() // => false34is({children: []}) // => false35is(node) // => true36is(node, 'strong') // => true37is(node, 'emphasis') // => false38 39is(node, node) // => true40is(parent, {type: 'paragraph'}) // => true41is(parent, {type: 'strong'}) // => false42 43is(node, test) // => false44is(node, test, 4, parent) // => false45is(node, test, 5, parent) // => true46```47 48## API49 50### `is(node[, test[, index, parent[, context]]])`51 52###### Parameters53 54* `node` ([`Node`][node]) — Node to check.55* `test` ([`Function`][test], `string`, `Object`, or `Array.<Test>`, optional)56 — When nullish, checks if `node` is a [`Node`][node].57 When `string`, works like passing `node => node.type === test`.58 When `array`, checks if any one of the subtests pass.59 When `object`, checks that all keys in `test` are in `node`,60 and that they have strictly equal values61* `index` (`number`, optional) — [Index][] of `node` in `parent`62* `parent` ([`Node`][node], optional) — [Parent][] of `node`63* `context` (`*`, optional) — Context object to invoke `test` with64 65###### Returns66 67`boolean` — Whether `test` passed *and* `node` is a [`Node`][node] (object with68`type` set to a non-empty `string`).69 70#### `function test(node[, index, parent])`71 72###### Parameters73 74* `node` ([`Node`][node]) — Node to check75* `index` (`number?`) — [Index][] of `node` in `parent`76* `parent` ([`Node?`][node]) — [Parent][] of `node`77 78###### Context79 80`*` — The to `is` given `context`.81 82###### Returns83 84`boolean?` — Whether `node` matches.85 86### `is.convert(test)`87 88Create a test function from `test`, that can later be called with a `node`,89`index`, and `parent`.90Useful if you’re going to test many nodes, for example when creating a utility91where something else passes an is-compatible test.92 93The created function is slightly faster because it expects valid input only.94Therefore, passing invalid input, yields unexpected results.95 96Can also be accessed with `require('unist-util-is/convert')`.97 98For example:99 100```js101var u = require('unist-builder')102var convert = require('unist-util-is/convert')103 104var test = convert('leaf')105 106var tree = u('tree', [107 u('node', [u('leaf', '1')]),108 u('leaf', '2'),109 u('node', [u('leaf', '3'), u('leaf', '4')]),110 u('leaf', '5')111])112 113var leafs = tree.children.filter((child, index) => test(child, index, tree))114 115console.log(leafs)116```117 118Yields:119 120```js121[{type: 'leaf', value: '2'}, {type: 'leaf', value: '5'}]122```123 124## Related125 126* [`unist-util-find-after`](https://github.com/syntax-tree/unist-util-find-after)127 — Find a node after another node128* [`unist-util-find-before`](https://github.com/syntax-tree/unist-util-find-before)129 — Find a node before another node130* [`unist-util-find-all-after`](https://github.com/syntax-tree/unist-util-find-all-after)131 — Find all nodes after another node132* [`unist-util-find-all-before`](https://github.com/syntax-tree/unist-util-find-all-before)133 — Find all nodes before another node134* [`unist-util-find-all-between`](https://github.com/mrzmmr/unist-util-find-all-between)135 — Find all nodes between two nodes136* [`unist-util-filter`](https://github.com/syntax-tree/unist-util-filter)137 — Create a new tree with nodes that pass a check138* [`unist-util-remove`](https://github.com/syntax-tree/unist-util-remove)139 — Remove nodes from tree140 141## Contribute142 143See [`contributing.md` in `syntax-tree/.github`][contributing] for ways to get144started.145See [`support.md`][support] for ways to get help.146 147This project has a [code of conduct][coc].148By interacting with this repository, organization, or community you agree to149abide by its terms.150 151## License152 153[MIT][license] © [Titus Wormer][author]154 155<!-- Definitions -->156 157[build-badge]: https://github.com/syntax-tree/unist-util-is/workflows/main/badge.svg158 159[build]: https://github.com/syntax-tree/unist-util-is/actions160 161[coverage-badge]: https://img.shields.io/codecov/c/github/syntax-tree/unist-util-is.svg162 163[coverage]: https://codecov.io/github/syntax-tree/unist-util-is164 165[downloads-badge]: https://img.shields.io/npm/dm/unist-util-is.svg166 167[downloads]: https://www.npmjs.com/package/unist-util-is168 169[size-badge]: https://img.shields.io/bundlephobia/minzip/unist-util-is.svg170 171[size]: https://bundlephobia.com/result?p=unist-util-is172 173[sponsors-badge]: https://opencollective.com/unified/sponsors/badge.svg174 175[backers-badge]: https://opencollective.com/unified/backers/badge.svg176 177[collective]: https://opencollective.com/unified178 179[chat-badge]: https://img.shields.io/badge/chat-discussions-success.svg180 181[chat]: https://github.com/syntax-tree/unist/discussions182 183[npm]: https://docs.npmjs.com/cli/install184 185[license]: license186 187[author]: https://wooorm.com188 189[contributing]: https://github.com/syntax-tree/.github/blob/HEAD/contributing.md190 191[support]: https://github.com/syntax-tree/.github/blob/HEAD/support.md192 193[coc]: https://github.com/syntax-tree/.github/blob/HEAD/code-of-conduct.md194 195[unist]: https://github.com/syntax-tree/unist196 197[node]: https://github.com/syntax-tree/unist#node198 199[parent]: https://github.com/syntax-tree/unist#parent-1200 201[index]: https://github.com/syntax-tree/unist#index202 203[test]: #function-testnode-index-parent204 