open-index/open-npm huggingface dataset:
npm package: @lanman2000/flow-to-ts
Description: Convert Flow code to TypeScript.
Latest version: 0.0.1

# flow-to-ts

Convert Flow code to TypeScript.

The goal of this project is to provide a tool that can translate 95% of Flow
to TypeScript while maintaining a high percentage of the existing type
information. We don't want to convert code and end up with everything using
`any`. We also want to avoid having to make a lot of manual changes to files
afterwards, e.g. changing `SyntheticEvent` to `React.Event`.

# Quick start

- `yarn global add @lanman2000/flow-to-ts`
- `flow-to-ts [options] <file globs>`

# Playground

https://flow-to-ts.netlify.com

# Principles

- when exact translation isn't possible:
  - downgrade to `any` when possible and provide a gentle warning
  - when it isn't possible to downgrade (e.g. `%checks`), remove the syntax
    and provide a forceful warning that the code in question will need a human
    to convert it manually.
- best effort to maintain blank lines and the position comments, this isn't
  always possible so warn in those situations where we can't, e.g. converting
  object type spreads to intersection types.

# Contibuting

## Bugs

Bug reports for converting Flow to TypeScript should include a link to the
playground with an example of a minimal reproducible example of the bug.

## Feature Requests

Feature requests are welcome.

## Pull Requests

Please make sure there is a GitHub issue first before creating a pull request
except for small things. Also, please sign our [Contributor License Agreement](https://docs.google.com/forms/d/e/1FAIpQLSdyXYrc8ogVoA46J9KXyIj5nKlZzNkOnQG-4A1R7X_BWGTShQ/viewform).

Pull requests that fix a bug in the conversion code should include one or more
test cases and should have 100% diff coverage.

## Helpful resources

- https://github.com/niieani/typescript-vs-flowtype
- https://astexplorer.net/
npm package: @lanmower/httpfs
Description: NHFS — Minimal HTTP file server
Author: Ali Sanan
Latest version: 0.2.7

# 📂 NHFS — Minimal HTTP File Server

<div align="center">
  A <strong>tiny, buildless file manager</strong> with Express backend and vanilla JavaScript frontend.
  Zero framework bloat. Just files.
</div>

---

## ✨ Features

- **Browse Files** — List directories with file metadata
- **Preview Files** — Images, audio, video inline
- **Drag-Drop Upload** — Upload files with progress
- **File Operations** — Delete, rename, move, mkdir
- **Responsive UI** — Works on mobile
- **Dark Mode** — CSS prefers-color-scheme
- **Path Security** — All paths validated against directory traversal

---

## 🚀 Quick Start

```bash
bunx httpfs
```

Open `http://localhost:3000`

For development:

```bash
git clone https://github.com/AnEntrypoint/NHFS.git
cd NHFS
bun install          # 5 seconds (2 dependencies only)
bun start            # Instant - no build needed
```

### Environment Variables

```bash
PORT=3000           # Server port (default: 3000)
BASE_DIR=/files     # Directory to serve (default: /files)
BASEPATH=           # URL subpath prefix (default: empty, e.g., /files for http://example.com/files/...)
```

---

## 📂 Architecture

**Backend: `server.js` (378 LOC)**
- Express server for file operations
- REST API: `/api/list`, `/api/upload`, `/api/download`, etc.
- Busboy for streaming multipart uploads
- Path injection prevention

**Frontend: Vanilla JavaScript (784 LOC)**
- `public/index.html` — Pure HTML (no JSX)
- `public/app.js` — DOM manipulation + fetch API
- `public/style.css` — Responsive CSS

**Dependencies: 2 only**
- `express` — HTTP server
- `busboy` — Multipart form parsing

---

## ✅ Why Buildless Works

NHFS is a file browser + uploader. It needs:
- REST API endpoints (Express does this)
- HTML/CSS/JS frontend (browsers run this directly)

It does NOT need:
- Server-side rendering
- JSX compilation
- CSS frameworks
- Type checking at runtime
- Build optimization

Result: **99.4% smaller node_modules, 0 build time**

---

## 📊 Metrics

| Metric | Before (Next.js) | After (Express) | Change |
|--------|-----------------|-----------------|--------|
| Dependencies | 47 packages | 2 packages | -95.7% |
| node_modules | 746MB | 4.7MB | -99.4% |
| Install time | 90s | 20s | -77% |
| Build time | 39.5s | 0s | -100% |
| Source code | 3105 LOC | 1161 LOC | -62.6% |

---

## 🛠 Development

```bash
npm start   # Run server
```

Edit `server.js`, `public/app.js`, or `public/style.css` and refresh browser. No build step.

---

## 📜 License

MIT
# Triggered npm publishing
npm package: @lanmower/roomba-js
Description: High-performance recursive node_modules removal tool
Latest version: 1.0.0

# roomba-js

⚡ High-performance recursive `node_modules` removal tool for Node.js projects.

## Features

- 🚀 **Ultra-fast** - Parallel processing with worker threads
- 🔍 **Smart scanning** - Recursively finds all `node_modules` folders
- 🛡️ **Safe removal** - Optional protection for workspace projects
- 💾 **Size tracking** - Reports disk space freed
- 🔒 **Dry run mode** - Preview before deletion
- 🖥️ **Cross-platform** - macOS, Windows (WSL/x86/x64/ARM), Linux

## Installation

### Global
```bash
npm install -g roomba-js
```

### Local
```bash
npm install --save-dev roomba-js
```

### npx (no install required)
```bash
npx roomba-js
```

## Usage

### Basic usage (cleans current directory)
```bash
roomba-js
```

### Clean specific directory
```bash
roomba-js /path/to/project
```

### Dry run (preview only)
```bash
roomba-js --dry-run
```

### Verbose output
```bash
roomba-js --verbose
```

### Force removal (skip protection checks)
```bash
roomba-js --force
```

### Custom worker count
```bash
roomba-js --concurrent 8
```

## Options

- `[path]` - Directory to clean (default: current directory)
- `-d, --dry-run` - Show what would be removed without actually removing
- `-v, --verbose` - Verbose output
- `-f, --force` - Force removal without protection checks
- `-c, --concurrent <number>` - Number of concurrent workers
- `-h, --help` - Display help
- `--version` - Display version

## Performance

roomba-js uses multiple techniques for maximum performance:

- **Parallel processing** with Node.js worker threads
- **Batch processing** to optimize I/O operations
- **Smart caching** to minimize filesystem calls
- **Chunked removal** to handle large directories efficiently

Typical performance: 10-50x faster than `rm -rf` for large projects.

## Safety Features

- **Workspace detection** - Protects npm/yarn workspaces by default
- **Dry run mode** - Preview before deletion
- **Error handling** - Continues on individual folder failures
- **Progress tracking** - Real-time status updates

## Examples

```bash
# Clean current directory with verbose output
roomba-js --verbose

# Preview what would be cleaned in a monorepo
roomba-js /path/to/monorepo --dry-run

# Force clean all node_modules (bypass protections)
roomba-js --force

# Use 4 parallel workers
roomba-js --concurrent 4
```

## API

```javascript
const { RoombaCleaner } = require('roomba-js');

const cleaner = new RoombaCleaner({
  dryRun: false,
  verbose: true,
  force: false,
  concurrent: 4
});

await cleaner.clean('/path/to/project');
```

## License

MIT
npm package: @lannis.ai/prisma-orm
Description: Shared Prisma schema for Lannis applications
Latest version: 0.1.8

# @lannis.ai/prisma-orm

A shared Prisma schema package for Lannis applications. This package provides only the Prisma schema definition that can be used across different projects to maintain database consistency.

## Features

- **Shared Prisma Schema**: Common schema definition for all Lannis applications
- **User Management Models**: Includes models for users, roles, and addresses
- **Financial Models**: Supports Monotributo categories and other financial entities
- **Location Data**: Includes models for countries and currencies

## Installation

```bash
npm install @lannis.ai/prisma-orm prisma @prisma/client
# or
yarn add @lannis.ai/prisma-orm prisma @prisma/client
```

## Usage

After installing the package, you need to:

1. Create a `prisma/schema.prisma` file in your project that references the shared schema:

```prisma
// Import the shared schema
import "@lannis.ai/prisma-orm/prisma/schema.prisma"

// You can add additional models or override settings here if needed
```

2. Configure your environment:

Create a `.env` file in your project root with your database connection:

```
DATABASE_URL="your-database-connection-string"
```

3. Generate the Prisma client:

```bash
npx prisma generate
```

4. Use the generated client in your code:

```typescript
import { PrismaClient } from '@prisma/client'

const prisma = new PrismaClient()

// Example: Query all users
async function getUsers() {
  const users = await prisma.user.findMany()
  return users
}
```

## Database Schema

The package includes the following main models:

- **User**: Core user entity with authentication and profile information
- **Address**: User address information linked to countries
- **Role**: User role definitions for access control
- **MonotributoCategory**: Argentine tax categories for monotributo
- **Country**: Country reference data
- **Currency**: Currency reference data

## Development

To work on this schema package:

1. Clone the repository
2. Install dependencies with `npm install` or `yarn`
3. Configure your `.env` file with a valid PostgreSQL connection string
4. Make your changes to the schema in `prisma/schema.prisma`
5. Test with `npx prisma validate`
6. Run migrations with `npm run db:migrate` for development testing

## License

MIT
npm package: @lannuttia/fibonacci
Description: A fibonacci number generator
Author: Anthony T. Lannutti
Latest version: 1.0.1

 # @lannuttia/fibonacci &middot; [![GitHub license](https://img.shields.io/badge/license-MIT-blue.svg)](https://github.com/lannuttia/fibonacci/blob/master/LICENSE) [![npm version](https://img.shields.io/npm/v/@lannuttia/fibonacci.svg?style=flat)](https://www.npmjs.com/package/@lannuttia/fibonacci)

 This is a simple library for generating fibonacci numbers. The business logic for this library was lifted from [here](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Iterators_and_Generators).
npm package: @lannuttia/telegram
Description: Generic brokers designed for routing information in a single process
Author: Anthony Lannutti
Latest version: 2.0.4

# Telegram &middot; [![Github License](https://img.shields.io/github/license/lannuttia/telegram.svg?style=plastic)](https://github.com/lannuttia/telegram/blob/master/LICENSE) [![Report an issue!](https://img.shields.io/github/issues/lannuttia/telegram.svg?style=plastic)](https://github.com/lannuttia/telegram/issues) [![Build](https://travis-ci.org/lannuttia/telegram.svg?branch=master)](https://travis-ci.org/lannuttia/telegram)
Telegram is a library for opaque data routing.
* **Simple:** Telegram allows you to easily start opaquely routing payloads.
* **Flexible:** With support for both the Publish/Subscribe pattern as well as the Request/Response pattern, you can passively receive updates or actively acquire data.
* **Loose Coupling** Never tightly couple your consumer code with the provider again. Whether acquiring data via HTTP, WebSockets, or an HTML5 postMessage, never have to modify you consumer code again just because the data source changed.

# Installation
Telegram is available on [npm](https://npmjs.org) as [@lannuttia/telegram](https://npmjs.org/package/@lannuttia/telegram).

# Documentation
Documentation can be found [here](https://lannuttia.github.io/telegram/@lannuttia/telegram/2.0.2/index.html).

# Examples
Coming soon...

# Contributing
If you have any type of feature request or bugfix, feel free to open an issue or submit a pull request. 

# License
Telegram is [MIT Licensed](https://github.com/lannuttia/telegram/blob/master/LICENSE).
npm package: @lano/morpheus
Description: Export your [Insomnia](https://insomnia.rest) workspace and test it in command line.
Author: jean-smaug
Latest version: 0.7.0

# Morpheus

Export your [Insomnia](https://insomnia.rest) workspace and test it in command line.

![demo](demo.gif)

## Installation

```bash
yarn add -DE @lano/morpheus jest
```

Create a `morpheus.config.js` and put this content

```js
// morpheus.config.js
module.exports = {
  verbose: true,
  rootDir: __dirname,
  snapshotResolver: "<rootDir>/node_modules/@lano/morpheus/snapshotResolver.js",
  testMatch: ["<rootDir>/node_modules/@lano/morpheus/tests/morpheus.spec.js"],
  testPathIgnorePatterns: []
};
```

## Usage

By default Morpheus search look for a file named `/Insomnia.*\.json/i`

```json
{
  "scripts": {
    "test:api": "jest --config=morpheus.config.js"
  }
}
```

## Example

The generated snapshot will look like the following. Keep in mind that the `date` header is removed to not break the snapshots.

```js
Object {
  "body": "OK",
  "description": "",
  "headers": Object {
    "connection": "close",
    "content-length": "2",
    "content-type": "text/plain; charset=utf-8",
  },
  "statusCode": 200,
  "url": "http://localhost:5000/auth/basic",
}
```

## To do

In `file.ts` take the most recent file using fs.statSync is there are multiples Insomnia files
npm package: @lanqiang/react-demo
Description: 第一个npm组件练习
Author: :username
Latest version: 7.0.1

npm发布注意事项：
注册 npm 账户：

在这里](https://www.npmjs.com/) 注册一个 npm 账号
npm login

然后你会得到一个让你输入username、password 和 email 的提示，把它们填在相应的位置。

关于 package.json 需要注意的点

package.json 里面的配置信息非常重要，我解释一下几个重要的配置。

name: 包名，如果你学习的话建议加一个 scoped，就是我上面的 @taoweng/react-demo 而不是 react-demo，因为 npm 包特别的多，很容易重复。这样这个包就会是私有的，可以通过 npm publish --access=public 将这个包变为共有的包。
version: 包的版本，每次发布包的版本不能和上次一样。详细规范可见这里
description：包的简介。
repository：适合写 Github 地址，建议写成：:username/:repository。
license：认证。不知道该用什么的，就写MIT 吧。
main：包的入口文件。就是引入这个包的时候去加载的入口文件。
keywords：添加一些关键词更容易使你的包被搜索到

在 GitHub Pages 上发布一个在线 demo
发布在线 demo 可以直接用 Github Pages 来帮助我们托管，通过 webpack 构建生产环境版本，然后发到 Github 上去即可。

首先去 Github 创建一个用来存放你组件代码的仓库。

把你的项目初始化成 git 项目
git init

##首次搭建组件包，需在终端执行此命令，连接远程仓库
git remote add origin https://github.com/lanqiang101/-lanqiang-react-demo.git

接下来我们可以安装 gh-pages 来帮助我们发布到 github pages：
npm i gh-pages -D
然后我们就可以 build 项目之后再将 expamples/dist 发布到 gh-pages 分支：
webpack --mode production
npm run build
gh-pages -d examples/dist

这个时候，我们可以通过 lanqiang101.github.io/-lanqiang-react-demo/ 访问到我们写的 lanqiang101 是 github 的 -lanqiang-react-demo/ 是仓库名，注意改成你自己的


这些命令我们可以写成 npm-scriprt，方便后面继续发布，所以我们增加两个脚本：

{
  "name": "@lanqiang/react-demo",
  "version": "7.0.0",
  "description": "第一个npm组件练习",
  "repository": ":username/:repository",
  "main": "index.js",
  "scripts": {
    "start": "webpack-dev-server --open development",
    "build": "webpack --mode production",
    "compile": "npx babel src --out-dir lib",
    "deploy": "gh-pages -d example/dist",
    "publish-demo": "npm run build && npm run deploy"
  },
  "keywords": [
    "npm组件",
    "组件发布",
    "npm发布步骤"
  ],
  "author": ":username",
  "license": "MIT",
  "devDependencies": {
    "@babel/cli": "^7.2.3",
    "@babel/core": "^7.2.2",
    "@babel/preset-env": "^7.3.1",
    "@babel/preset-react": "^7.0.0",
    "babel-loader": "^8.0.5",
    "gh-pages": "^2.2.0",
    "html-webpack-plugin": "^3.2.0",
    "webpack": "^4.29.0",
    "webpack-cli": "^3.2.1",
    "webpack-dev-server": "^3.1.14"
  },
  "dependencies": {
    "@babel/polyfill": "^7.2.5",
    "react": "^16.7.0",
    "react-dom": "^16.7.0"
  }
}

添加了 deploy 脚本和 publish-demo，以后需要发布 demo 的时候只需要 npm run publish-demo即可

结语
以后发布新版本的时候，只需要更改一下 package.json 里面的 version 版本号，然后执行 npm publish 和 npm run publish-demo 就可以同步 npm 和 demo

npm publish --access public：发布公共组件，免费，私包需要收费
npm package: @lanred/discordjs-button-embed-pagination
Description: Discord.js V14 embed pagination with button
Author: Amal Zacharia
Latest version: 5.0.2

# discordjs-button-embed-pagination

<p>
	<a href="https://discord.gg/5DRwubYxmj"><img src="https://img.shields.io/discord/658881908733771816?color=5865F2&logo=discord&logoColor=white" alt="Discord server" /></a>
		<a href="https://www.npmjs.com/package/discordjs-button-embed-pagination"><img src="https://img.shields.io/npm/v/discordjs-button-embed-pagination.svg?maxAge=3600" alt="NPM version" /></a>
	<a href="https://www.npmjs.com/package/discordjs-button-embed-pagination"><img src="https://img.shields.io/npm/dt/discordjs-button-embed-pagination.svg?maxAge=3600" alt="NPM downloads" /></a>
</p>

## About

Discord.js V14 embed pagination with button written in typescript

**Features:**

- Send paginated embeds


**Useful links:**
- [Documentation](https://crza5.github.io/discordjs-button-embed-pagination/)
- [Examples](https://github.com/CRZA5/discordjs-button-embed-pagination/tree/master/examples)
- [Discord.js Server](https://discord.gg/djs)
- [Repository](https://github.com/CRZA5/discordjs-button-embed-pagination)

## Installation
**Discord.js v14**
- npm
```bash
npm i discord.js
```
- yarn 
```bash
yarn add discord.js
```
**discordjs-button-embed-pagination**
- npm
```bash
npm i discordjs-button-embed-pagination
```
- yarn
```bash
yarn add discordjs-button-embed-pagination
```

## Demo 
![](examples/example.png)
npm package: @lanren0721/common
Description: Technical analysis utilities extracted from lanren project
Latest version: 1.0.1

# @lanren0721/common

常用技术与市场工具函数库，支持 Node ESM。

## 安装

```bash
npm install @lanren0721/common
```

## 使用示例

```js
import { getTechAnalysis, technical, market } from '@lanren0721/common';

// 技术分析主入口
const tech = await getTechAnalysis(klineData, endDate);

// 或分别使用子模块
const { calculateIndicators, analyzeTrend } = technical;
const { getMarketType, marketCode2Name } = market;
```

## 导出清单

### 根入口（index.js）
- `getTechAnalysis(klineData, endDate)` —— 综合技术分析主函数
- `technical` —— 技术指标与趋势分析命名空间（见下）
- `market` —— 市场工具命名空间（见下）

### technical 子模块（lib/technical/index.js）
- `getTechAnalysis` —— 同上，可被直接导入
- 重导出以下全部指标与趋势函数：

#### 指标函数（lib/technical/indicators/index.js）
- `calculateIndicators(klineData)` —— 一键计算全部指标
- `calculateRSI(prices, period=14)`
- `calculateMACD(prices)`
- `calculateKDJ(prices, highs, lows)`
- `calculateBOLL(prices)`
- `calculateIchimoku(prices)`
- `calculateOBV(klineData)`
- `calculateSAR(highs, lows)`
- `calculateFibonacci(prices)`
- `calculateBIAS(prices)`
- `calculateVolumeRatio(klineData)`
- `calculateMagicNine(prices)`
- `calculateDragonSignal({ macd, kdj, rsi, prices })`
- `calculateChipDistribution(prices)`
- `calculateMA(prices)` —— 多均线
- `calculateWR(prices, highs, lows)`
- `calculateDMI(prices, highs, lows)`
- `calculateTRIX(prices)`

#### 趋势/策略分析（lib/technical/analyzers/trendAnalyzer.js）
- `analyzeTrend({ indicators, currentPrice, prevPrice, klineData })` —— 综合趋势研判

#### 通用工具（lib/technical/common/index.js）
- `calculateMA10(klineData)`
- `analyzeUptrendPullback(klineData, ma10Data, baseVolume)`
- `generateStrategyAnalysis(...)` —— 策略评分与建议
- `getConfidenceLevel(score)` —— 置信度级别
- `combinePriceTrend(short, mid, long)` —— 多周期趋势合并
- 更多辅助函数……

### market 子模块（lib/market/index.js）
- `marketParamsMap` —— 市场代码→东财 API 参数映射表
- `marketNewTypeMap` —— 市场简称映射
- `marketCode2Name(marketCode)` —— 代码转市场名称
- `getMarketFromCode(code)` —— 旧版市场编号推断
- `getNewMarketFromCode(code)` —— 新版市场类型字符串推断
- `getMarketType(code)` —— 返回 `'a' | 'hk' | 'us' | null`
- `getMarketInfo(code)` —— 返回 `{ market, type }` 完整信息
- `market2ItickMarket(code)` —— 转换为 itick 市场标识

## 发布日志
- 1.0.0  初始发布，包含完整技术指标与趋势分析
- 1.1.0  新增 market 工具模块，补充市场编码相关函数
npm package: @lanrey/sails-postgresql
Description: a postgreSQL adapter for Waterline and Sails.js
Author: Cody Stoltman
Latest version: 0.12.4

![image_squidhome@2x.png](http://i.imgur.com/RIvu9.png)

# PostgreSQL Sails/Waterline Adapter

[![Build Status](https://travis-ci.org/balderdashy/sails-postgresql.png?branch=master)](https://travis-ci.org/balderdashy/sails-postgresql) [![NPM version](https://badge.fury.io/js/sails-postgresql.png)](http://badge.fury.io/js/sails-postgresql)

A [Waterline](https://github.com/balderdashy/waterline) adapter for PostgreSQL. May be used in a [Sails](https://github.com/balderdashy/sails) app or anything using Waterline for the ORM.

## Install

Install is through NPM.

```bash
$ npm install sails-postgresql
```

## Configuration

The following config options are available along with their default values:

```javascript
config: {
  database: 'databaseName',
  host: 'localhost',
  user: 'root',
  password: '',
  port: 5432,
  poolSize: 10,
  ssl: false
};
```
Alternatively, you can supply the connection information in URL format:
```javascript
config: {
  url: 'postgres://username:password@hostname:port/database',
  ssl: false
};
```


We are also testing features for future versions of waterline in postgresql. One of these is case sensitive string searching. In order to enable this feature today you can add the following config flag:

```javascript
postgresql: {
  url: 'postgres://username:password@hostname:port/database',
  wlNext: {
    caseSensitive: true
  }
}
```

## Model Level Config

You can use model level config options to specify a `schema` to use. This is done by adding the `meta` key `schemaName`.

```javascript
module.exports = Waterline.Collection.extend({
  tableName: 'user',
  meta: {
    schemaName: 'foo'
  },

  identity: 'user',
  connection: 'myAwesomeConnection',

  attributes: {
    name: 'string'
  }
});
```

## Testing

Test are written with mocha. Integration tests are handled by the [waterline-adapter-tests](https://github.com/balderdashy/waterline-adapter-tests) project, which tests adapter methods against the latest Waterline API.

To run tests:

```bash
$ npm test
```

## About Waterline

Waterline is a new kind of storage and retrieval engine.  It provides a uniform API for accessing stuff from different kinds of databases, protocols, and 3rd party APIs.  That means you write the same code to get users, whether they live in mySQL, LDAP, MongoDB, or Facebook.

To learn more visit the project on GitHub at [Waterline](https://github.com/balderdashy/waterline).
npm package: @lansecong/lowcode-materials
Description: Fusion Next for LowCode
Latest version: 0.4.6
Deprecated: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.

# [Fusion Materials](https://github.com/alibaba-fusion/next) for LowCode

## 体验地址/Demo

<https://alifd.alicdn.com/npm/@alilc/lowcode-materials@1.0.1/build/lowcode/index.html>

## 使用/Usage

### 引用 npm 包/npm

```
const { material } from '@alilc/lowcode-engine';
const assets = require('@alilc/lowcode-materials/dist/assets.json');

// in GeneralWorkbench init
material.setAssets(assets);
```


#### 低代码/LowCode

```
npm run lowcode:dev
npm run lowcode:build
```

#### 源码/ProCode

```
npm start
npm run build
```



npm config set registry https://registry.npmjs.org/

npm config set registry https://mirrors.tencent.com/npm/

wget https://cdn.npmmirror.com/binaries/node/v14.19.1/node-v14.19.1-linux-x64.tar.xz
npm package: @lansenger/openclaw-channel-lansenger
Description: 蓝信机器人插件 - 让 AI 助手接入蓝信，无需服务器 | Lanxin channel plugin for OpenClaw
Author: lxfe
Latest version: 1.1.15

# Lansenger (蓝信) 通道插件 for OpenClaw

通过 WebSocket 长连接连接 Lansenger 机器人（无需公网服务器）。

## 功能特性

- WebSocket 长连接实现实时消息传递
- 多账号支持
- 不同机器人的路由管理
- 基于会话的隔离
- 单文件打包，增强安全性
- 代码混淆保护

## 安装

### 通过 OpenClaw CLI 安装（推荐）

```bash
# 安装 Lansenger 通道插件
openclaw plugins install @lansenger/openclaw-channel-lansenger
```

## 构建

### 开发模式（源码模式）

```bash
npm run src
```

这将切换到源码模式，直接使用 TypeScript 源码运行。

### 生产模式（打包模式）

```bash
npm run dist
```

这将切换到生产模式，使用打包后的单文件。

### 构建命令

```bash
# 构建生产版本（完整构建 + 切换到dist模式）
npm run build

# 仅构建不切换模式
npm run build:src

# 构建 openclaw 版本
npm run build:openclaw
```

## 打包安全性特性

生产模式使用 esbuild 进行打包，提供以下安全特性：

1. **单文件打包**：所有代码打包成单个文件，减少代码暴露面
2. **代码混淆**：
   - 属性名混淆（以 `_` 开头的属性会被混淆）
   - 高度压缩
3. **环境变量处理**：
   - `process.env.WS_NO_UTF_8_VALIDATE` 被替换为 `false`
   - 其他 `process.env` 引用被替换为空对象

## 使用

### 添加 AppId 命令

您可以使用命令行添加 Lansenger 机器人账号：

```bash
openclaw channels add --channel Lansenger --token "{AppID}:{AppSecret}:{APIGateway}:{AgentId}"
```

**参数说明**：
- `--channel Lansenger`：指定通道名称为 Lansenger
- `--token`：包含以下信息的令牌
  - `{AppID}`：蓝信机器人的 AppID
  - `{AppSecret}`：蓝信机器人的 AppSecret
  - `{APIGateway}`：蓝信 API 网关地址 支持https/http协议
  - `{AgentId}`：(可选) 绑定的 OpenClaw Agent ID

**使用示例**：

```bash
openclaw channels add --channel Lansenger --token "123123-123123:ABHCDEFE:https://gateway.cn:agentId"
```

此命令将：
1. 解析令牌并提取 AppID、AppSecret、API 网关地址和 AgentId
2. 在配置文件中自动添加或更新账号信息
3. 如果提供了 AgentId，自动生成对应的 binding 配置
4. 自动启用 Lansenger 通道

**注意**：使用此命令后，无需手动修改 `openclaw.json` 配置文件，系统会自动处理所有配置。


### Agent 隔离功能

Lansenger 插件支持每个 appId 与单独的 agent 绑定，实现独立的通信和会话管理：

**实现效果**：
- 不同的蓝信机器人（appId）可以绑定到不同的 OpenClaw agent
- 每个 agent 拥有独立的会话上下文和工作区
- 消息会自动路由到对应绑定的 agent
- 支持多机器人同时运行，互不干扰

**配置方式**：
1. 在添加账号时指定 agentId：
   ```bash
   openclaw channels add --channel Lansenger --token "{AppID}:{AppSecret}:{APIGateway}:{AgentId}"
   ```

2. 系统会自动在配置文件中生成绑定关系：
   ```json
   "bindings": [
     {
       "type": "route",
       "agentId": "coder",
       "match": { "channel": "Lansenger", "accountId": "bot_15294464" }
     },
     {
       "type": "route",
       "agentId": "friend",
       "match": { "channel": "Lansenger", "accountId": "bot_11100160" }
     }
   ]
   ```

**使用示例**：
- 机器人 A (appId: your-app-id-1) 绑定到 agent: friend
- 机器人 B (appId: your-app-id-2) 绑定到 agent: coder
- 两个机器人可以同时运行，拥有独立的会话和上下文


## 故障排除

### 会话隔离

如果您遇到会话隔离问题，请确保：
1. 您已在 OpenClaw 配置中正确配置了绑定
2. 每个机器人在配置中使用不同的 accountId
3. 每个 agent 有自己的工作区

### 消息路由

如果消息没有路由到正确的 agent：
1. 检查您的绑定配置
2. 确保绑定中的 accountId 与通道配置中的 accountId 匹配
3. 更改配置后重启 OpenClaw

### 速率限制问题

如果在安装过程中遇到 `Rate limit exceeded` 错误：
1. 在短暂延迟后尝试重新安装插件
2. 如果需要，重复安装过程几次
3. 速率限制通常是临时的，应该在几分钟内解决

## 日志

日志可在 OpenClaw 日志目录中找到。查找带有 `[Lansenger]` 前缀的日志。
npm package: @lanserdi/scheduling-table
Description: VUE-based scheduling components
Author: lanserdi@163.com
Latest version: 1.4.8

安装依赖
```
npm i
```

开发模式启动项目
```
npm run serve
```


从 NPM 下载该组件
```bash
npm i -S @lanserdi/scheduling-table
```

在你的 VUE 项目模板中使用该组件
```vue
<SchedulingTable
    @add="add"
    @remove="remove"
    @edit="showEditCourseModal"
    v-model="courses"
  ></SchedulingTable>
```
npm package: @lanseria/utools
Description: A U Tools
Author: Lanseria
Latest version: 1.0.3

# @lanseria/utools

Alternative JavaScript Tool Library

[文档](https://lanseria.github.io/utools/)

```bash
yarn add @lanseria/utools
```

## 功能

### tree

- [x] treeForeach
- [x] treeMap
- [x] treeToList
- [x] treeToListById

### list

- [ ] listToTree

### utils

- [x] treeClone
- [x] treeCloneById
- [x] mergeProperties
npm package: @lanseria/v-pdf
Description: A Vue 3 Pdf Tools
Author: Lanseria
Latest version: 1.0.8

<h1 align="center">VPDF</h1>
<p align="center">A Vue 3 PDF TOOLS</p>

<p align="center">English | <a href="README.zh-CN.md">中文</a></p>

## Documentation

[https://github.com/Lanseria/v-pdf#readme](https://github.com/Lanseria/v-pdf#readme)

## Features

- 支持 PDF 预览
- 仅支持 vue 3
- 支持 PDF 文字复制

## Installation

### npm

Use npm to install.

```bash
npm i -D @lanseria/v-pdf
```

### USE

```vue
<template>
  <v-pdf-viewer
    src="https://cdn.filestackcontent.com/wcrjf9qPTCKXV3hMXDwK"
  ></v-pdf-viewer>
</template>
```

## Contributing

Please see [CONTRIBUTING.md](https://github.com/Lanseria/v-pdf/blob/main/CONTRIBUTING.md).

## License

v-pdf is licensed under the [MIT license](https://opensource.org/licenses/MIT).

## Reference

### Vue PDF.js Demo

This project demonstrates how a simple PDF viewer could be implemented using Vue and PDF.js. This is not a fully-featured PDF document viewer with sophisticated controls, but could serve as the basis for one.

[Index](https://rossta.net/vue-pdfjs-demo)

To learn more, checkout [the series of posts](https://rossta.net/blog/series/pdf-viewer.html) describing how this project was implemented.

1. [Basic page rendering](https://rossta.net/blog/building-a-pdf-viewer-with-vue-part-1.html)
1. [Fetching and rendering lazily](https://rossta.net/blog/building-a-pdf-viewer-with-vue-part-2.html)
1. [Extracting a data component](https://rossta.net/blog/extracting-a-data-component-in-vue.html)
1. [Refactoring to nested abstract components](https://rossta.net/blog/refactoring-to-nested-abstract-components-vuejs-pdf-viewer.html)

### pdfvuer

[Index](https://github.com/arkokoley/pdfvuer)

### pdf.js doc

[Doc](https://mozilla.github.io/pdf.js/api/draft/index.html)

### pdf.js viewer code

[web/app.js](https://github.com/mozilla/pdf.js/blob/master/web/app.js)

### set pdf.js viewer locale

[issues](https://github.com/mozilla/pdf.js/issues/11829)

### vue full feature pdf.js demo

[github](https://github.com/sandanat/vue-pdf-app)
npm package: @lanseria/vue-pdf-vite
Description: This project is for the vitejs vuejs3 pdfjs-dist pdf-lib library, built together with the components
Latest version: 1.0.5

# vue-pdf-useinvite

此项目为 vitejs vuejs3 pdfjs-dist pdf-lib 库, 一起构建的组件

This project is for the vitejs vuejs3 pdfjs-dist pdf-lib library, built together with the components

## npm / yarn 安装

```bash
npm i @lanseria/vue-pdf-vite

yarn add @lanseria/vue-pdf-vite
```

## 引入 @lanseria/vue-pdf-vite

```js
import "@lanseria/vue-pdf-vite/style.css";
```

```vue
<template>
  <pdf-editor
    src="http://183.131.134.242:1889/files/20210619/383518b085f9469eb9ec34594196f8c7.pdf"
  ></pdf-editor>
</template>

<script lang="ts">
import { defineComponent } from "vue";
import { PdfEditor } from "@lanseria/vue-pdf-vite";
// import { PdfViewer } from "@lanseria/vue-pdf-vite";

export default defineComponent({
  name: "App",
  components: {
    PdfEditor,
  },
});
</script>
```

## 效果

<img src="./doc/pdf-view.png"/>
<img src="./doc/pdf-edit.png"/>

## 具体 TODO
npm package: @lanshu/system-common
Description: 后台系统-公共组件
Author: wudong
Latest version: 0.0.16

# 公共模块

> 主要承载两个部分：公共配置中心：webpack等项目公共配置；公共组件：包含UI组件和功能组件

Tips: 可以使用全局变量`CONFIG`

## assets

### 公共样式

- normalize.css
- variable.less
> 变量名统一加上大写`R`前缀
- layout.less
> 全局类名统一加上`r-`前缀

### 字体图标

## Store

- global
- user

## Utils

- https: axios
- utils

## API

- options
- user: 登录权限相关

## Component

## Webpack

- 需要全局注入的配置CONFIG
npm package: @lansonai/vad-types
Description: TypeScript types for voice activity detection (VAD).
Author: LansonAI
Latest version: 0.1.0

# @lansonai/vad-types

TypeScript types for Voice Activity Detection (VAD).

- Website: https://lansonai.com

## Install

```bash
npm i @lansonai/vad-types
```

## Usage

```ts
import type { VadEngine, VadFrame, VadSegment, VadOptions } from "@lansonai/vad-types";
```

## What’s inside

- `AudioFormat`, `VadFrame`, `VadOptions`
- `VadSegment`, `VadResult`
- `VadEngine` interface (sync or async implementations)
npm package: @lantah/txrep
Description: Convert from to and from txrep (SEP0011) and XDR
Latest version: 2.0.0

# @stellarguard/txrep

[![Latest Version](https://img.shields.io/npm/v/@stellarguard/txrep.svg)](https://img.shields.io/npm/v/@stellarguard/txrep.svg)
[![NodeJS Support](https://img.shields.io/node/v/@stellarguard/txrep.svg)](https://img.shields.io/node/v/@stellarguard/txrep.svg)

A TypeScript/JavaScript implementation of [SEP-0011](https://github.com/stellar/stellar-protocol/blob/master/ecosystem/sep-0011.md), a human-readable Stellar transaction representations.

## Installation

```bash
npm install @stellarguard/txrep --save
# or
yarn add @stellarguard/txrep
```

## Examples

[See a live demo](https://stellarguard.github.io/txrep/demo)

### Converting a Transaction to Txrep

```js
import { toTxrep } from '@stellarguard/txrep';
import { Transaction, Networks } from '@lantah/lantah-sdk';

const xdr = 'AAAAACsWS5BDhC5BjpKQtznHFJ3CkU6+XtWopW+t+Q9KoH7QAAAAZAClKY0AAAABAAAAAQAAAABbicmAAAAAAF1q/QAAAAABAAAAFkVuam95IHRoaXMgdHJhbnNhY3Rpb24AAAAAAAEAAAAAAAAAAQAAAABAXzbt2M8i77+AcrmFtqTAFVHDTdOME3rI1A1ALNH3tAAAAAFVU0QAAAAAADJSVDIhkp9uz61Ra68rs3ScZIIgjT8ajX8Kkdc1be0LAAAAABfXk6AAAAAAAAAAAUqgftAAAABA3vtPH60cJ5MntVrxhP3N33P096jLQOflNKcdc6BRJLo2nbem0xtHyv0RhZIkaoV15sJJq5TsN2je22KSIhzlDA=='
const tx = new Transaction(xdr, Networks.TESTNET);
const txrep = toTxrep(tx);
```

### Converting Txrep to Transaction

### Creating and signing a transaction URI

```js
import { toTransaction } from '@stellarguard/txrep';
import { Networks } from '@lantah/lantah-sdk';

const txrep = `
tx.sourceAccount: GAVRMS4QIOCC4QMOSKILOOOHCSO4FEKOXZPNLKFFN6W7SD2KUB7NBPLN
tx.fee: 100
tx.seqNum: 46489056724385793
tx.timeBounds._present: true
tx.timeBounds.minTime: 1535756672 (Fri Aug 31 16:04:32 PDT 2018)
tx.timeBounds.maxTime: 1567292672 (Sat Aug 31 16:04:32 PDT 2019)
tx.memo.type: MEMO_TEXT
tx.memo.text: "Enjoy this transaction"
tx.operations.len: 1
tx.operations[0].sourceAccount._present: false
tx.operations[0].body.type: PAYMENT
tx.operations[0].body.paymentOp.destination: GBAF6NXN3DHSF357QBZLTBNWUTABKUODJXJYYE32ZDKA2QBM2H33IK6O
tx.operations[0].body.paymentOp.asset: USD:GAZFEVBSEGJJ63WPVVIWXLZLWN2JYZECECGT6GUNP4FJDVZVNXWQWMYI
tx.operations[0].body.paymentOp.amount: 400004000 (40.0004e7)
tx.ext.v: 0
signatures.len: 1
signatures[0].hint: 4aa07ed0 (GAVRMS4QIOCC4QMOSKILOOOHCSO4FEKOXZPNLKFFN6W7SD2KUB7NBPLN signer for account GAVRMS4QIOCC4QMOSKILOOOHCSO4FEKOXZPNLKFFN6W7SD2KUB7NBPLN)
signatures[0].signature: defb4f1fad1c279327b55af184fdcddf73f4f7a8cb40e7e534a71d73a05124ba369db7a6d31b47cafd118592246a8575e6c249ab94ec3768dedb6292221ce50c
`;

const tx = toTransaction(txrep, Networks.TESTNET);
```

## Contributing

Want to contribute? Consider adding additional test cases to [tests.yaml](./tests.yaml).

You can install the reference implementation at https://github.com/xdrpp/stc and then convert XDRs using: `stc example.xdr`