open-index/open-npm huggingface dataset:
npm package: @jeremysnr/snug-anthropic
Description: snug for the Anthropic SDK. Fit messages into a token budget with automatic tool_use/tool_result pair handling.
Author: Jeremy Smith
Latest version: 0.1.1

# @jeremysnr/snug-anthropic

[![npm](https://img.shields.io/npm/v/@jeremysnr/snug-anthropic)](https://www.npmjs.com/package/@jeremysnr/snug-anthropic)
[![license](https://img.shields.io/npm/l/@jeremysnr/snug-anthropic)](./LICENSE)

Fit Anthropic messages into a token budget. Automatically handles `tool_use`/`tool_result` pairing so you never get a 400 error from an orphaned tool message.

```ts
import { fitMessages } from '@jeremysnr/snug-anthropic';

const { messages } = fitMessages(conversationHistory, {
  budget: 100000,
  reserve: 4096,
});

const response = await client.messages.create({
  model: 'claude-opus-4-5',
  max_tokens: 4096,
  messages,
});
```

Messages are prioritised by recency — older messages are dropped first. `tool_use` and `tool_result` pairs are kept together automatically; if one half doesn't fit, both are dropped.

## Install

```
npm install @jeremysnr/snug-anthropic
```

`@anthropic-ai/sdk` must be installed as a peer dependency.

## API

### `fitMessages(messages, options)`

| Option | Type | Default | Description |
|--------|------|---------|-------------|
| `budget` | `number` | — | Token limit |
| `reserve` | `number` | `0` | Tokens to hold back for the model's reply |

**Returns**

```ts
{
  messages: MessageParam[];  // ready to send
  dropped: MessageParam[];   // what didn't fit
  tokensUsed: number;
  tokensRemaining: number;
}
```

## Part of the snug ecosystem

- [`@jeremysnr/snug`](https://github.com/JeremySNR/snug) — zero-dependency core primitive
- [`@jeremysnr/snug-tiktoken`](https://github.com/JeremySNR/snug-tiktoken) — snug with tiktoken, model-agnostic
- [`@jeremysnr/snug-openai`](https://github.com/JeremySNR/snug-openai) — snug for the OpenAI SDK

## Licence

MIT
npm package: @jeremysnr/snug-openai
Description: snug for the OpenAI SDK. Fit chat messages into a token budget, ready to pass to client.chat.completions.create.
Author: Jeremy Smith
Latest version: 0.1.1

# @jeremysnr/snug-openai

[![npm](https://img.shields.io/npm/v/@jeremysnr/snug-openai)](https://www.npmjs.com/package/@jeremysnr/snug-openai)
[![license](https://img.shields.io/npm/l/@jeremysnr/snug-openai)](./LICENSE)

Fit OpenAI chat messages into a token budget. Pass the result directly to `client.chat.completions.create`.

```ts
import { fitMessages } from '@jeremysnr/snug-openai';

const { messages } = fitMessages(conversationHistory, {
  model: 'gpt-4o',
  budget: 8192,
  reserve: 1024,
});

const response = await client.chat.completions.create({ model: 'gpt-4o', messages });
```

System messages are always kept. Other messages are prioritised by recency — older messages are dropped first when the budget is tight.

## Install

```
npm install @jeremysnr/snug-openai
```

`openai` must be installed as a peer dependency.

## API

### `fitMessages(messages, options)`

| Option | Type | Default | Description |
|--------|------|---------|-------------|
| `budget` | `number` | — | Token limit |
| `reserve` | `number` | `0` | Tokens to hold back for the model's reply |
| `model` | `TiktokenModel` | `'gpt-4o'` | Used to select the tiktoken encoding |

**Returns**

```ts
{
  messages: ChatCompletionMessageParam[];  // ready to send
  dropped: ChatCompletionMessageParam[];   // what didn't fit
  tokensUsed: number;
  tokensRemaining: number;
}
```

## Part of the snug ecosystem

- [`@jeremysnr/snug`](https://github.com/JeremySNR/snug) — zero-dependency core primitive
- [`@jeremysnr/snug-tiktoken`](https://github.com/JeremySNR/snug-tiktoken) — snug with tiktoken, model-agnostic
- [`@jeremysnr/snug-anthropic`](https://github.com/JeremySNR/snug-anthropic) — snug for the Anthropic SDK

## Licence

MIT
npm package: @jeremysnr/snug-tiktoken
Description: snug pre-wired with tiktoken. Zero config token counting for OpenAI and Anthropic models.
Author: Jeremy Smith
Latest version: 0.1.1

# @jeremysnr/snug-tiktoken

[![npm](https://img.shields.io/npm/v/@jeremysnr/snug-tiktoken)](https://www.npmjs.com/package/@jeremysnr/snug-tiktoken)
[![license](https://img.shields.io/npm/l/@jeremysnr/snug-tiktoken)](./LICENSE)

[snug](https://github.com/JeremySNR/snug) pre-wired with [tiktoken](https://github.com/openai/tiktoken). Accurate token counting for OpenAI and Anthropic models with no setup.

```ts
import { fit } from '@jeremysnr/snug-tiktoken';

const result = fit(
  [
    { id: 'system',  content: systemPrompt,  priority: 100 },
    { id: 'history', content: chatHistory,   priority:  60 },
    { id: 'rag',     content: retrievedDocs, priority:  40 },
  ],
  { budget: 8192, reserve: 1024 },
);
```

Defaults to `cl100k_base` encoding, which is accurate for all current OpenAI and Anthropic models. Pass `model` to use a model-specific encoding:

```ts
fit(items, { budget: 4096, model: 'gpt-3.5-turbo' });
```

## Install

```
npm install @jeremysnr/snug-tiktoken
```

## Why

`@jeremysnr/snug` is zero-dependency and requires you to supply a tokenizer. This package removes that step for the common case.

## Licence

MIT
npm package: @jeremysu0131/seo-checker
Description: This is used to check your SEO file.
Author: Jeremy Su
Latest version: 1.0.1

[![Build Status](https://travis-ci.org/jeremysu0131/seo-checker.svg?branch=master)](https://travis-ci.org/jeremysu0131/seo-checker)

# SEO Checker

## Features

1. Check if the HTML file applies the SEO rules.
2. You can use `Stream` to Read/Write file.

## Installing

Using npm:

```bash
npm install @jeremysu0131/seo-checker
```

## Input Methods

1. `readFile`: Read a HTML file
2. Use `fs.createReadStream` to create a read stream, then use `pipe` to pipe chunk to the method you specified.

## Check Methods

1. `checkImage`: Detect if any `img` tag without alt attribute
2. `checkLink`: Detect if any `a` tag without rel attribute
3. `checkTitle`: Detect if header doesn’t have `title` tag
4. `checkMeta`: Detect if header doesn’t have the tag you specified
5. `checkStrong`: Detect if there’re more than 15 `strong` tag in HTML (15 is a default value and you can configurable by yourself)
6. `checkH1`: Detect if a HTML have more than one `h1` tag

## Output Methods

1. `printResultsToConsole`: Print check results to console
2. `writeResultsToFile`: Write results to file
3. **Custom**: You can write your custom results style by pipe the chunk to your custom method

## Example

Performing a read HTML file sample

```js
import { Check } from '@jeremysu0131/seo-checker';

Check.readFile('./test.html')
  .checkImage()
  .checkH1()
  .checkMeta('keywords', 'descriptions')
  .printResultsToConsole();

// Output:
// <h1> tag is more than one. Total: 2
// Meta have "keywords" but not have "descriptions"
// There are 2 <img> tag without alt attribute.
```

Performing a read HTML file as Stream sample

```js
import fs from 'fs';
import { CheckStream } from '@jeremysu0131/seo-checker';

// Create a read stream
const rs = fs.createReadStream('./test.html');

// Pipe the stream to every method
rs.pipe(CheckStream.detectImage())
  .pipe(CheckStream.detectLink())
  .pipe(CheckStream.detectTitle())
  .pipe(CheckStream.detectMeta('keywords', 'descriptions'))
  .pipe(CheckStream.detectStrong())
  .pipe(CheckStream.detectH1())
  .pipe(CheckStream.writeResultsToFile('./test.txt')); // Save results to file
```
npm package: @jeremyvignelles/tmdb-ts
Description: TMDB v3 library wrapper
Author: Blake Joynes
Latest version: 1.5.1

# tmdb-ts


Typescript library wrapper of [TMDB API](https://developers.themoviedb.org/) v3 .


[![Version npm](https://img.shields.io/npm/v/tmdb-ts.svg?style=flat-square)](https://www.npmjs.com/package/tmdb-ts)[![npm Downloads](https://img.shields.io/npm/dm/tmdb-ts.svg?style=flat-square)](https://npmcharts.com/compare/tmdb-ts?minimal=true)

This uses new jwt authentication token for requests so there is no need to append api key to the url. 
Once you have registered for access to the api you can use your access token as follows:

Installation:
``
npm install --save tmdb-ts
``

Version 1.0 removed the default import so make sure you update accordingly!

```js
import { TMDB } from 'tmdb-ts';

const tmdb = new TMDB('accessToken');

try {
   const movies = await tmdb.search.movies({ query: 'American Pie' });
   console.log(movies);
} catch(err) {
   // handle error
}
```
npm package: @jeremyy_prt/cc-config
Description: Configuration personnalisée pour Claude Code avec commandes et agents en français
Author: Jeremy
Latest version: 1.2.2

# CC Config

Config Claude Code en français avec commandes, agents et scripts.

## Installation

**Prérequis:** [Claude Code](https://claude.ai/download) installé

```bash
npx @jeremyy_prt/cc-config setup
```

⚠️ **Important:** Ne pas utiliser `npm install`, utiliser `npx` avec `setup`

## Contenu

**7 Commandes:**
- `/commit` - Commits rapides avec push auto
- `/corriger-orthographe` - Correction grammaire/orthographe
- `/creer-agent` - Créer des agents
- `/creer-commande` - Créer des commandes
- `/liste-commande` - Lister tout avec exemples
- `/memoire-claude` - Gérer les fichiers CLAUDE.md
- `/surveiller-ci` - Auto-fix des erreurs CI

**4 Agents:**
- `@corriger-orthographe` - Correction de fichiers
- `@explorer-code` - Explorer le code
- `@explorer-docs` - Explorer la doc
- `@recherche-web` - Recherche web

**Sécurité:**
- Hook de validation bash (bloque `rm -rf /`, `sudo`, etc.)

**Statusline:**
- Branche Git avec modifications (`main*`)
- Contexte utilisé (`23%`)
- Limites d'usage (`Session: 45%`)
- Compatible **Mac ET Windows** ✅

**Bonus:**
- Sons de notification
- Hooks configurés

## Exemples

```bash
# Commit rapide
/commit

# Corriger fichier
/corriger-orthographe src/app.vue

# Explorer doc
@explorer-docs cherche Nuxt 4

# Surveiller CI
/surveiller-ci

# Lister tout
/liste-commande --exemples
```

## Config optionnelle

**Context7** pour @explorer-docs:
```bash
claude mcp add --transport http context7 https://mcp.context7.com/mcp
```

**Alias shell** pour lancer Claude en bypass:
```bash
# Ajouter dans ~/.zshrc ou ~/.bashrc
alias cc='claude --dangerously-skip-permissions'
alias ccc='claude --dangerously-skip-permissions -c'
```

## License

MIT
npm package: @jeresiliemoncontrat/vanilla-cookieconsent
Description: 🍪 Simple cross-browser cookie-consent plugin written in vanilla js.
Author: Orest Bida
Latest version: 3.1.0

# CookieConsent v3

[![License: MIT](https://img.shields.io/badge/License-MIT-green.svg)](https://opensource.org/licenses/MIT)
[![Latest version](https://img.shields.io/github/package-json/v/orestbida/cookieconsent?color=2b4eed&label=Release)](https://github.com/orestbida/cookieconsent/releases/v3.0.0)
[![CircleCI](https://dl.circleci.com/status-badge/img/gh/orestbida/cookieconsent.svg?style=svg)](https://dl.circleci.com/status-badge/redirect/gh/orestbida/cookieconsent)

A __lightweight__ & __gdpr compliant__ cookie consent plugin written in plain javascript.

![CookieConsent v3 cover](demo/assets/cover.png "Cover")

## Demo
Check out the [playground](https://playground.cookieconsent.orestbida.com).

There are also a few examples available on [Stackblitz](https://stackblitz.com/@orestbida/collections/cookieconsent-v3).

## Documentation
Docs. available at [cookieconsent.orestbida.com](https://cookieconsent.orestbida.com).

## Contributing
Please read the [contribution guide](/CONTRIBUTING.md).

Thanks to all the people who already contributed!

<a href="https://github.com/orestbida/cookieconsent/graphs/contributors">
  <img src="https://contrib.rocks/image?repo=orestbida/cookieconsent" />
</a>

<br>
<br>

A special thanks goes [Till Sanders](https://github.com/tillsanders) for creating and maintaining the npm package!

## License
Distributed under the MIT License. See [LICENSE](https://github.com/orestbida/cookieconsent/blob/master/LICENSE) for more information.
npm package: @jeresiliemoncontrat/vite-plugin-symfony
Description: A Vite plugin to integrate easily Vite in your Symfony application
Author: Hugues Tavernier
Latest version: 8.2.2

<div>
  <p align="center">
  <img width="100" src="https://raw.githubusercontent.com/lhapaipai/vite-bundle/main/docs/symfony-vite.svg" alt="Symfony logo">
  </p>
  <p align="center">
    <img src="https://img.shields.io/npm/v/vite-plugin-symfony?style=flat-square&logo=npm">
    <img src="https://img.shields.io/github/actions/workflow/status/lhapaipai/symfony-vite-dev/vite-plugin-symfony-ci.yml?style=flat-square&label=vite-plugin-symfony%20CI&logo=github">
  </p>
</div>


# Vite plugin Symfony

> [!IMPORTANT]
> This repository is a "subtree split": a read-only subset of that main repository [symfony-vite-dev](https://github.com/lhapaipai/symfony-vite-dev) which delivers to packagist only the necessary code.

> [!IMPORTANT]
> If you want to open issues, contribute, make PRs or consult examples you will have to go to the [symfony-vite-dev](https://github.com/lhapaipai/symfony-vite-dev) repository.

A Vite plugin to easily integrate Vite into your Symfony application.

- create a `entrypoints.json` file inside your build directory with your js/css/preload dependencies.
- reload your browser when you update your twig files

This package is intended for use with the Symfony Bundle : [pentatrion/vite-bundle](https://github.com/lhapaipai/vite-bundle).


## Installation

```console
npm i vite-plugin-symfony
```

Create this directory structure :
```
├──assets
│ ├──app.js
│ ├──app.css
│...
├──public
├──composer.json
├──package.json
├──vite.config.js
```

Vite base config with vite

```js
// vite.config.js
import {defineConfig} from "vite";
import symfonyPlugin from "vite-plugin-symfony";

export default defineConfig({
    plugins: [
        symfonyPlugin(/* options */),
    ],

    build: {
        rollupOptions: {
            input: {
              app: "./assets/app.js" /* relative to the root option */
            },
        },
    }
});
```

and your package.json :
```json
{
    "scripts": {
        "dev": "vite",
        "build": "vite build"
    },
    "devDependencies": {
        "vite": "^5.0",
        "vite-plugin-symfony": "^8.2"
    }
}
```

[Read the Docs to Learn More](https://symfony-vite.pentatrion.com).

## Ecosystem

| Package                                                                 | Description               |
| ----------------------------------------------------------------------- | :------------------------ |
| [vite-bundle](https://github.com/lhapaipai/vite-bundle)                 | Symfony Bundle (read-only)|
| [symfony-vite-dev](https://github.com/lhapaipai/symfony-vite-dev)       | Package for contributors  |

## License

[MIT](LICENSE).
npm package: @jeresiliemoncontrat/vite-plugin-vue-facing-decorator-hmr
Description: Fix HMR support for Vue components with vue-facing-decorator
Author: Yoann Laissus
Latest version: 1.0.2

A Vite plugin fixing HMR support for Vue components using vue-facing-decorator without using the recommended toNative method.

## How to use it
```javascript
// vite.config.js
import vueFacingDecoratorHmr from "vite-plugin-vue-facing-decorator-hmr";

export default {
  plugins: [vueFacingDecoratorHmr()]
}
```

## Some context : 
The vue-facing-decorator library recommends to call this method on every Vue components :
```javascript
@Component
export class MyComp extends Vue{}
export default toNative(MyComp)
```

Not doing that will break Vite HMR on every Vue components.

But, using toNative totally breaks some IDE (WebStorm : https://youtrack.jetbrains.com/issue/WEB-64939/Vue-3-vue-facing-decorator-toNative).

This plugin allows you to not declare toNative() in your Vue component to keep good IDE support but to still enjoy Vite HMR.

Under the hood, it's adding toNative() automatically during the Vite build process.

## License

MIT License © 2024 [Arakmar](https://github.com/Arakmar)
npm package: @jeretigerxu/miniscule
Description: Removes all spaces from a string
Latest version: 2.0.0

## @jeretigerxu/miniscule

![npm (scoped)](https://img.shields.io/npm/v/@jeretigerxu/miniscule)

![npm bundle size (scoped)](https://img.shields.io/bundlephobia/min/@jeretigerxu/miniscule)

This is my first attempt at creating an `npm` package.

### Install

`$ npm install @jeretigerxu/miniscule`

### Usage

```javascript
const mini = require("@jeretigerxu/miniscule");

mini("So much space!");
//=> "Somuchspace!"

tiny(1337);
//=> Uncaught TypeError: Miniscule wants a string!
//    at miniscule (<anonymous>:2:41)
//    at <anonymous>:1:1
```
npm package: @jerexyz/giturl
Description: Transfer git url to web url
Author: fengmk2
Latest version: 1.0.1

giturl
=======

[![Build Status](https://secure.travis-ci.org/repo-utils/giturl.png)](http://travis-ci.org/repo-utils/giturl)

[![Coverage Status](https://coveralls.io/repos/repo-utils/giturl/badge.png)](https://coveralls.io/r/repo-utils/giturl)

[![Dependency Status](https://gemnasium.com/repo-utils/giturl.png)](https://gemnasium.com/repo-utils/giturl)

[![NPM](https://nodei.co/npm/giturl.png?downloads=true&stars=true)](https://nodei.co/npm/giturl/)

![logo](https://raw.github.com/repo-utils/giturl/master/logo.png)

Transfer git url to web url.

## Install

```bash
$ npm install giturl
```

## Usage

```js
var giturl = require('giturl');

giturl.parse('git://gitlab.com/edp/logger.git');
// => http://gitlab.com/edp/logger

giturl.parse('git@gitlab.com:edp/logger.git');
// => http://gitlab.com/edp/logger

giturl.parse('git://github.com/treygriffith/cellar.git');
// => https://github.com/treygriffith/cellar

giturl.parse('https://jpillora@github.com/banchee/tranquil.git');
// => https://github.com/banchee/tranquil

giturl.parse('https://jpillora@github.com/banchee/tranquil.git');
// => https://github.com/banchee/tranquil

giturl.parse('git@github.com:cnpm/cnpm.git');
// => https://github.com/cnpm/cnpm

giturl.parse('git@gitcafe.com:fengmk2/cnpm.git');
// => http://gitcafe.com/fengmk2/cnpm

giturl.parse('http://github.com/component/emitter/archive/1.0.1.tar.gz')
// => https://github.com/component/emitter
```

## License

(The MIT License)

Copyright (c) 2014 fengmk2 &lt;fengmk2@gmail.com&gt; and other contributors

Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
'Software'), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:

The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
npm package: @jerexyz/postcss-plugin-prefix
Description: PostCSS plugin postcss plugin for add css selector prefix
Author: Jared
Latest version: 1.0.0

# PostCSS Plugin Prefix

[PostCSS] plugin postcss plugin for add css prefix.

[postcss]: https://github.com/postcss/postcss

```css
/* Input example */
a {
}
.ant-test {
}
```

```css
/* Output example */
#test a {
}
#test .ant-test {
}
```

## Usage

Check you project for existed PostCSS config: `postcss.config.js`
in the project root, `"postcss"` section in `package.json`
or `postcss` in bundle config.

If you already use PostCSS, add the plugin to plugins list:

```diff
module.exports = {
  plugins: [
+   require('@jerexyz/postcss-plugin-prefix')({
+      prefix: '#test',
+      matchRule: (selector) => {
+        if (/^.ant/.test(selector)) {
+          return true;
+        }
+        if (!/^[.#]/.test(selector)) {
+          return true;
+        }
+        return false;
+      },
+    }),
    require('autoprefixer')
  ]
}
```

If you do not use PostCSS, add it according to [official docs]
and set this plugin in settings.

[official docs]: https://github.com/postcss/postcss#usage