V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
V2EX  ›  riceball  ›  全部回复第 1 页 / 共 2 页
回复总数  33
1  2  
@uprit 人家是学习,cpu 足够了,微调个 7b int qlora 。真要训练,那不得上服务集群。
@ltaoo1o 是的,需要机器支持。gem12pro 有接口
如果个人实验,现在的纯 cpu(最好 amd ) 可以跑 70b 4int 量化用 llamacpp ,不过很慢,但能忍。30b 以下很快。
这时限制在内存,内存尽可能要大,内存至少要 32G, 最好 64G , 然后支持 Oculink 接口,外接显卡。这样的 miniPC 机器 我配了一台 天呗 gem12pro 2400 + 4t ssd + 64g DDR5 大概 5k 左右
还有这个 https://ml5js.org/
10 天前
回复了 lerry 创建的主题 Linux 记一次 ZFS 存储池恢复实战
@ryd994 崩溃后,已经没用 zfs 了,当时我主用 zfs ,连 root 和 boot 分区都是 zfs, 导致挂了后不能启动,一直卡在 scrub.

另外,现在想来,zfs 最好还是要经常 cron scrub 。我的 ZFS 系统当时已经稳定工作很长的一段的时间(大概 3 年),一直到仓库快满了,才出现的问题。

对桌面 PC 来说,是的,compression 不是问题。但是基于应用级的压缩无法做到压缩后的数据在整个盘中只保存一份,而 dedup 能做到。

自从 zfs 挂了,我现在用的就是支持 bbu cache 的 raid 卡,当时买成 900 多,带超级电容,1G RAM ,现在只要 400 多(不带超级电容)。raid 上是纯机械硬盘,放需要安全保存的数据; ssd 只放 boot 分区,以及需要加速的应用和数据。
10 天前
回复了 lerry 创建的主题 Linux 记一次 ZFS 存储池恢复实战
@ryd994 就因为 zfs 有 dedup 才用的,省硬盘。如果不用的话,为啥不直接 mdadm,组软 raid ,后期直接上 raid 卡也成。
11 天前
回复了 galileo1214 创建的主题 程序员 现阶段,最好的 Agent 框架是什么?
取决于你想干啥,比如,🙆‍♀️也许想这么干:

翻译家.ai.yaml

---
input: ['lang', 'text']
output: {type: 'object', properties: {target_text: {type: string}}}
parameters:
temperature: 0
---
system: 你是全球最棒的多语言翻译家。
user: 请直接把接下来的文字翻译为{{lang}}:"{{text}}"
assistant: [[AI]]
-> json(output)


nodejs 调用:

import {AIScript} from '@...'
const result = await AIScript.execFile('翻译家.ai.yaml', {text: 'here is text', lang: '中文'})
// result: {target_text: '这是文本'}
11 天前
回复了 lerry 创建的主题 Linux 记一次 ZFS 存储池恢复实战
我的一点使用 ZFS 的❄️的教训:

1. 必须至少上 RegRAM,还有就是尽可能多的 RAM,至少要满足最小值,具体计算我忘记了,根据你组的磁盘总大小计算,尤其是你启用了 deduplication, 它严重依赖 RAM ,如果 RAM 有错误,写入就会错误!
2. 当 ZFS 快写满了,如果这时候仓库错误,恢复几乎不太可能,折腾几天,几乎进度不动。我的数据...
Good ,推荐基于这个弄: https://github.com/apify/crawlee easily Extract data for AI, LLMs. Works with Puppeteer, Playwright, Cheerio, JSDOM, and raw HTTP. Both headful and headless mode. 并添加了自己的反屏蔽功能和类人指纹。

这个要单独分几块弄

1. 建立 UI 自动化脚本规范,要简单易懂,能很自然扩展到桌面应用,采用类自然语言,使得 LLM 更好理解
2. 开发 UI 自动化脚本引擎库
3. 设计 PPE 可编程提示词工程(引擎),目的是规范化提示词,使 AI 提示任务工程化,简单化,打通代码和 LLM 之间的 gap ,这个我在弄,目前部分开源: https://github.com/offline-ai/cli 目前进展是实现了类自然语言的结构化聊天消息,只实现了 js 可以像调普通函数一样调用 llm 提示词任务, 反过来 llm 提示词也可以调用任意 js 或其他 PPE. PPE 支持继承,import,export. 还没作广泛宣传,自我感觉完成度不高,仅在 Linux 上开发测试。有一两个应用例子. 提示词这块坑多,模型规模越小,坑越多。大模型也有坑,所以想通过规范化提示词避坑。
4. 引入 UI 自动化脚本引擎库,让 LLM 调用.
14 天前
回复了 kran 创建的主题 Java 你喜欢使用 Java 下的哪个 web 框架?
VertX 太底层!不过,如果你正在寻找一个能够快速开发高性能 Web 应用的框架,那 Play Framework 是一个极佳的选择。它支持 Java 和 Scala ,好像是从 3.0 开始用 scala 重写底层的,采用异步模型处理请求,非常适合构建高并发的应用。内置热部署功能让你在开发时可以即时看到代码改动的效果,极大地提高了开发效率。同时,简洁的路由配置、强大的表单处理机制和内置模板引擎都使得开发变得更加直观和高效。对于想要构建 RESTful API 的开发者来说,Play 提供了流畅的支持和工具。

sbt new playframework/play-java-seed.g8
15 天前
回复了 angrylid 创建的主题 NAS 24 岁,感觉到了玩 NAS 的年纪,求推荐。
供参考:DIY 自己的开源 NAS https://riceball.me/article/diy-cloud-computing-2/
应该是太贵,本地离线 llm 高端 pc 才带得动,小设备没戏。如果只是 online.所有的现在的伪智能音箱厂家只要后端改下服务接口就可以做到,只是服务而已,随时可以切换,也可以随时跑路,比如京东智能音箱
16 天前
回复了 freesun165 创建的主题 git 求助 git 自动 merge 丢代码
还是 Git 操作要有规范,这个彼此合并,左右互搏,啧啧,建议使用 Git flow 规范,有 git 插件支持: https://danielkummer.github.io/git-flow-cheatsheet/index.zh_CN.html
@drymonfidelia OnPointerUp 在最前面就是个错误顺序,放这里也一样,`Start OnPointerUp Awake OnPointerDown OnBeginDrag OnDrag OnEndDrag`。这个提示词思想是让它按事件发生的先后顺序来讲解,因此与你写在里面的顺序无关. 另外如果要让纠正名称错误,最好单独一个提示词,一次只让它做一件事也能提高成功率。
但说实话,我发现它在语法纠错上不是很好,尤其是漏字,可能是没有针对这块精调过。
提示词没有设计好,因为这个的确算小众知识,如果要激发出来,提示词是关键。

我的测试是,本地 7B 左右的 LLM 基本没戏,激发也没用,已经吃不准了,而 qwen2.5 则没戏,估计是一点都没有学过。
7B 左右只有 gemma9B 经过二次提醒,能搞对顺序。30b 左右的基本能一次搞定。

[PPE(Programable Prompt Engine)]( https://github.com/offline-ai/cli)提示词如下:

```yaml
---
parameters:
temperature: 0
---
system: |-
You are a helpful Unity programming expert in the world. You know the Unity knowledge very well. You are very careful and precise.
Think about the user's intention carefully and solve the problem step by step.
---
user: |-
Please tell me the order in which the following Unity events occur:
OnPointerUp Start Awake OnPointerDown OnBeginDrag OnDrag OnEndDrag
assistant: "[[AI]]"
```

`ai run unity.ai.yaml`的执行结果(gemma-27b):

```
user: Please tell me the order in which the following Unity events occur:
OnPointerUp Start Awake OnPointerDown OnBeginDrag OnDrag OnEndDrag


unity: Here's the order of those Unity events, along with a brief explanation of each:

1. **Awake:** This event is called once when the script instance is being loaded, before any Start functions are called.

2. **Start:** This event is called once at the beginning of the game, after all Awake functions have been called.

3. **OnPointerDown:** This event is triggered when the user starts pressing down on a UI element or a GameObject with a
Collider.

4. **OnBeginDrag:** This event is triggered when the user starts dragging the UI element or GameObject after pressing down.

5. **OnDrag:** This event is triggered continuously while the user is dragging the UI element or GameObject.

6. **OnPointerUp:** This event is triggered when the user releases the mouse button or touch input.

7. **OnEndDrag:** This event is triggered when the user finishes dragging the UI element or GameObject.

**Important Notes:**

* These events are typically used with UI elements or GameObjects that have colliders attached.
* The order can be slightly modified depending on specific user interactions and the setup of your UI or game.



Let me know if you have any other Unity event-related questions!
```

gemma9B 经过二次提醒的提示词:

```yaml
---
parameters:
temperature: 0
---
system: |-
You are a helpful Unity programming expert in the world. You know the Unity knowledge very well. You are very careful and precise.
Think about the user's intention carefully and solve the problem step by step.
---
user: |-
Please tell me the order in which the following Unity events occur:
OnPointerUp Start Awake OnPointerDown OnBeginDrag OnDrag OnEndDrag
assistant: "[[AI]]"
user: |-
Hint: Please think about OnPointerUp in Unity carefully.
assistant: "[[AI]]"
```

执行结果:

```
user: Please tell me the order in which the following Unity events occur:
OnPointerUp Start Awake OnPointerDown OnBeginDrag OnDrag OnEndDrag


unity: Here's the order in which those Unity events occur, along with a brief explanation of each:

1. **Awake:** This method is called once, when the script instance is being loaded. It's used to initialize variables and set up
initial conditions.

1. **Start:** This method is called once, after Awake, and before the first frame update. It's often used to perform setup tasks
that require access to the GameObject's components or other game objects.

1. **OnPointerDown:** This event is triggered when the user presses a mouse button or touches the screen over your GameObject.

2. **OnBeginDrag:** This event is triggered when the user starts dragging an object. This usually happens after `OnPointerDown`
and only if the object is set up to be draggable.

1. **OnDrag:** This event is triggered repeatedly while the user is dragging the object.

2. **OnEndDrag:** This event is triggered when the user releases the mouse button or lifts their finger from the screen, ending
the drag operation.

1. **OnPointerUp:** This event is triggered when the user releases the mouse button or lifts their finger from the screen. It
occurs after `OnEndDrag` if the drag operation was initiated.


**Important Notes:**

* The exact order of events can vary slightly depending on the specific Unity version and the context of the events.
* `OnPointerDown` and `OnPointerUp` are more general events that can occur for any interaction with the mouse or touch input.
`OnBeginDrag`, `OnDrag`, and `OnEndDrag` are specifically related to dragging operations.



Let me know if you have any other questions about Unity events or need further clarification!

user: Hint: Please think about OnPointerUp in Unity carefully.

unity: You're right, I need to be more careful about `OnPointerUp`.

While it's generally triggered when the user releases the mouse button or finger, it's not *always* directly after `OnEndDrag`.

Here's a more precise order, taking `OnPointerUp` into account:

1. **Awake:** Initialization of script variables.
2. **Start:** Setup tasks after Awake.
3. **OnPointerDown:** Mouse button pressed or touch initiated on the GameObject.
4. **OnBeginDrag:** Drag operation starts if the GameObject is set up for dragging.
5. **OnDrag:** Repeatedly triggered while dragging.
6. **OnPointerUp:** Triggered when the mouse button or finger is released.
* **Important:** This can happen *before* `OnEndDrag` if the user releases the button without completing the drag.

7. **OnEndDrag:** Triggered when the drag operation officially ends (usually after `OnPointerUp` if the drag was completed).



Let me know if you have any more questions!
```
209 天前
回复了 logictan89 创建的主题 奇思妙想 有没有基于 AI 的个人秘书?
啊,这些不都是别人家的秘书,这下老王又可以八卦了. 自己本地电脑跑开源 LLM 脑子不香么,
自架 LLM

* https://github.com/facebookresearch/fairseq/tree/main/examples/mms 可识别 4000 多种语言、错误率仅为 OpenAI 产品的一半
* https://github.com/google-research/multilingual-t5
2023-06-14 20:07:32 +08:00
回复了 QianyanSanren 创建的主题 程序员 现在个人开发游戏,推荐去学习哪种语言?
如果和 aurora4x 非常类似,那么可以考虑直接在现有开源项目上 fork 修改: https://github.com/Pulsar4xDevs/Pulsar4x
2023-06-14 19:45:15 +08:00
回复了 godleon 创建的主题 程序员 [讨论一个开源的想法] 针对 web 端,想做一个有交互的升级
是 web 端么? 如果只是浏览器访问,那么必然就 PWA 了,关于 PWA 可以使用资源的预缓存机制,google 提供的 Workbox 工具箱简化使用.

如果是跨平台的 JS 应用,那么要看你用的是啥了,react native? cordova? capacitor? flutter? 基本上都有热更新, 微软贡献的开源项目 code-push 不错

1. https://github.com/microsoft/react-native-code-push
2. https://github.com/microsoft/cordova-plugin-code-push
3. https://github.com/mapiacompany/capacitor-codepush
1  2  
关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   5873 人在线   最高记录 6679   ·     Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 31ms · UTC 06:16 · PVG 14:16 · LAX 22:16 · JFK 01:16
Developed with CodeLauncher
♥ Do have faith in what you're doing.