<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Qwen on Harry AI</title><link>https://harryai.cc/tags/qwen/</link><description>Recent content in Qwen on Harry AI</description><generator>Hugo -- gohugo.io</generator><language>zh-cn</language><managingEditor>harryliuwx888@gmail.com (Harry)</managingEditor><webMaster>harryliuwx888@gmail.com (Harry)</webMaster><copyright>Copyright © 深圳市网旭科技有限公司。&lt;a href="https://beian.miit.gov.cn/" target="_blank">粤ICP备14077691号&lt;/a></copyright><lastBuildDate>Fri, 19 Jul 2024 15:16:01 +0800</lastBuildDate><atom:link href="https://harryai.cc/tags/qwen/index.xml" rel="self" type="application/rss+xml"/><item><title>如何利用本地模型，将音视频整理成一份结构化的Markdown笔记</title><link>https://harryai.cc/post/audio-notes/</link><pubDate>Fri, 19 Jul 2024 15:16:01 +0800</pubDate><author>harryliuwx888@gmail.com (Harry)</author><guid>https://harryai.cc/post/audio-notes/</guid><description>&lt;p>项目地址：&lt;a href="https://github.com/harry0703/AudioNotes">https://github.com/harry0703/AudioNotes&lt;/a>&lt;/p>
&lt;h2 id="基于-funasr-和-qwen2-构建的音视频转结构化笔记系统">基于 FunASR 和 Qwen2 构建的音视频转结构化笔记系统&lt;/h2>
&lt;p>能够快速提取音视频的内容，并且调用大模型进行整理，成为一份结构化的markdown笔记，方便快速阅读&lt;/p>
&lt;p>FunASR: &lt;a href="http://localhost:15433/">https://github.com/modelscope/FunASR&lt;/a>&lt;/p>
&lt;p>Qwen2: &lt;a href="http://localhost:15433/">https://ollama.com/library/qwen2&lt;/a>&lt;/p>
&lt;h2 id="效果展示">效果展示&lt;/h2>
&lt;h3 id="音视频识别和整理">音视频识别和整理&lt;/h3>
&lt;img src="https://harryai.cc/post/audio-notes/1.jpg" alt="image">&lt;h3 id="与音视频内容对话">与音视频内容对话&lt;/h3>
&lt;img src="https://harryai.cc/post/audio-notes/2.jpg" alt="image">&lt;h2 id="使用方法">使用方法&lt;/h2>
&lt;h3 id="-安装-ollama">① 安装 Ollama&lt;/h3>
&lt;p>下载对应系统的 Ollama 安装包进行安装&lt;/p>
&lt;p>&lt;a href="http://localhost:15433/">https://ollama.com/download&lt;/a>&lt;/p>
&lt;h3 id="-拉取模型">② 拉取模型&lt;/h3>
&lt;p>我以 &lt;code>阿里的千问2 7b&lt;/code> 为例 &lt;a href="http://localhost:15433/">https://ollama.com/library/qwen2&lt;/a>&lt;/p>
&lt;div class="highlight">&lt;div style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">
&lt;table style="border-spacing:0;padding:0;margin:0;border:0;">&lt;tr>&lt;td style="vertical-align:top;padding:0;margin:0;border:0;">
&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">&lt;code>&lt;span style="white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f" id="hl-0-1">&lt;a style="outline:none;text-decoration:none;color:inherit" href="#hl-0-1">1&lt;/a>
&lt;/span>&lt;/code>&lt;/pre>&lt;/td>
&lt;td style="vertical-align:top;padding:0;margin:0;border:0;;width:100%">
&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">&lt;code class="language-bash" data-lang="bash">&lt;span style="display:flex;">&lt;span>ollama pull qwen2:7b
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/td>&lt;/tr>&lt;/table>
&lt;/div>
&lt;/div>&lt;h3 id="docker部署推荐">Docker部署（推荐）🐳&lt;/h3>
&lt;div class="highlight">&lt;div style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">
&lt;table style="border-spacing:0;padding:0;margin:0;border:0;">&lt;tr>&lt;td style="vertical-align:top;padding:0;margin:0;border:0;">
&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">&lt;code>&lt;span style="white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f" id="hl-1-1">&lt;a style="outline:none;text-decoration:none;color:inherit" href="#hl-1-1">1&lt;/a>
&lt;/span>&lt;span style="white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f" id="hl-1-2">&lt;a style="outline:none;text-decoration:none;color:inherit" href="#hl-1-2">2&lt;/a>
&lt;/span>&lt;/code>&lt;/pre>&lt;/td>
&lt;td style="vertical-align:top;padding:0;margin:0;border:0;;width:100%">
&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">&lt;code class="language-bash" data-lang="bash">&lt;span style="display:flex;">&lt;span>curl -fsSL https://harryai.cc/audio-notes/docker-compose.yml -o docker-compose.yml
&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>docker-compose up
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/td>&lt;/tr>&lt;/table>
&lt;/div>
&lt;/div>&lt;p>docker 启动后，访问 &lt;a href="http://localhost:15433/">http://localhost:15433/&lt;/a>&lt;/p>
&lt;blockquote>
&lt;p>登录账号为 admin，密码为 admin （可以在 docker-compose.yml 文件里面修改）&lt;/p>&lt;/blockquote>
&lt;h3 id="本地部署-">本地部署 📦&lt;/h3>
&lt;p>需要有可访问的 postgresql 数据库&lt;/p>
&lt;div class="highlight">&lt;div style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">
&lt;table style="border-spacing:0;padding:0;margin:0;border:0;">&lt;tr>&lt;td style="vertical-align:top;padding:0;margin:0;border:0;">
&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">&lt;code>&lt;span style="white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f" id="hl-2-1">&lt;a style="outline:none;text-decoration:none;color:inherit" href="#hl-2-1">1&lt;/a>
&lt;/span>&lt;span style="white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f" id="hl-2-2">&lt;a style="outline:none;text-decoration:none;color:inherit" href="#hl-2-2">2&lt;/a>
&lt;/span>&lt;span style="white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f" id="hl-2-3">&lt;a style="outline:none;text-decoration:none;color:inherit" href="#hl-2-3">3&lt;/a>
&lt;/span>&lt;span style="white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f" id="hl-2-4">&lt;a style="outline:none;text-decoration:none;color:inherit" href="#hl-2-4">4&lt;/a>
&lt;/span>&lt;span style="white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f" id="hl-2-5">&lt;a style="outline:none;text-decoration:none;color:inherit" href="#hl-2-5">5&lt;/a>
&lt;/span>&lt;/code>&lt;/pre>&lt;/td>
&lt;td style="vertical-align:top;padding:0;margin:0;border:0;;width:100%">
&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">&lt;code class="language-bash" data-lang="bash">&lt;span style="display:flex;">&lt;span>conda create -n AudioNotes python&lt;span style="color:#f92672">=&lt;/span>3.10 -y
&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>conda activate AudioNotes
&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>git clone https://github.com/harry0703/AudioNotes.git
&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>cd AudioNotes
&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>pip install -r requirements.txt
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/td>&lt;/tr>&lt;/table>
&lt;/div>
&lt;/div>&lt;p>将 &lt;code>.env.example&lt;/code> 重命名为 &lt;code>.env&lt;/code>，修改相关配置信息&lt;/p>
&lt;div class="highlight">&lt;div style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">
&lt;table style="border-spacing:0;padding:0;margin:0;border:0;">&lt;tr>&lt;td style="vertical-align:top;padding:0;margin:0;border:0;">
&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">&lt;code>&lt;span style="white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f" id="hl-3-1">&lt;a style="outline:none;text-decoration:none;color:inherit" href="#hl-3-1">1&lt;/a>
&lt;/span>&lt;/code>&lt;/pre>&lt;/td>
&lt;td style="vertical-align:top;padding:0;margin:0;border:0;;width:100%">
&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">&lt;code class="language-bash" data-lang="bash">&lt;span style="display:flex;">&lt;span>chainlit run main.py
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/td>&lt;/tr>&lt;/table>
&lt;/div>
&lt;/div>&lt;p>服务启动后，访问 http://localhost:8000/&lt;/p>
&lt;blockquote>
&lt;p>登录账号为 admin，密码为 admin （可以在 docker-compose.yml 文件里面修改）&lt;/p>&lt;/blockquote></description></item></channel></rss>