Overseas access: www.kdjingpai.com
Ctrl + D Favorites

General Introduction

Fabric is an open source AI framework developed by Daniel Miessler to simplify and automate everyday computer tasks and make artificial intelligence easier to use. It helps users efficiently handle various matters such as content summarization, data extraction and automated writing through modular design and preset prompt words (Patterns).Fabric supports the integration of multiple large language models, and users can customize the settings according to their needs, which greatly enhances their work efficiency and learning ability.

Fabric One of its main functions is to help people gather tips and integrate them into all aspects of their lives, which we call Patterns.

Fabric:集成众多提示词的AI开源工作流框架,高效处理各种事务-1

 

Function List

  • modular design: Break down complex tasks into simple steps with Patterns.
  • Multi-platform support: Can be easily installed and used on different operating systems.
  • command-line interface: Users can operate via the CLI for those who prefer the command line.
  • API Integration: Support for integration with multiple AI model providers such as OpenAI, Anthropic, and more.
  • Customized tips: Users can create and edit their own prompts to meet specific needs.
  • Local Model Support: Allows users to set up local AI models for processing.
  • Interactive settings: The installation process is simple and provides interactive configuration options.

 

Using Help

Installation process

# Windows:
curl -L https://github.com/danielmiessler/fabric/releases/latest/download/fabric-windows-amd64.exe > fabric.exe && fabric.exe --version

# MacOS (arm64):
curl -L https://github.com/danielmiessler/fabric/releases/latest/download/fabric-darwin-arm64 > fabric && chmod +x fabric && ./fabric --version

# MacOS (amd64): 
curl -L https://github.com/danielmiessler/fabric/releases/latest/download/fabric-darwin-amd64 > fabric && chmod +x fabric && ./fabric --version

# Linux (amd64): 
curl -L https://github.com/danielmiessler/fabric/releases/latest/download/fabric-linux-amd64 > fabric && chmod +x fabric && ./fabric --version

# Linux (arm64):
curl -L https://github.com/danielmiessler/fabric/releases/latest/download/fabric-linux-arm64 > fabric && chmod +x fabric && ./fabric --version

 

To install Fabric.Make sure you have Go installed!, and then run the following command.

# Install Fabric directly from the repo
go install github.com/danielmiessler/fabric@latest

 

set up

# Run the setup to set up your directories and keys
fabric --setup

 

Usage Process

  1. Basic Command Usage::
    Fabric provides a series of commands to perform different tasks. For example, to extract key points from a YouTube video and generate a blog post, you can use the following commands:

    yt https://www.youtube.com/watch?v=视频ID | fabric -p extract_wisdom | fabric -p write_essay | fabric -sp translate_cn
    
  2. Custom Model Selection::
    You can pass the -m parameter to select a different model. For example, change the default model to an open source model:

    fabric -m nousresearch/hermes-3-llama-3.1-405b: free
    
  3. Frequently Asked Questions::
    If you're having trouble installing or using it, you can visit GitHub's Issues page to see feedback from other users or ask your own questions.
  4. Community Support and Outreach::
    Fabric encourages users to participate in the development of new Patterns and features, and users can submit their contributions on GitHub.

 

All commands

用法:
fabric [OPTIONS]

应用程序选项:
-p, --pattern= 从可用的模式中选择一个模式
-v, --variable= 设置模式变量的值,例如 -v=#role:expert -v=#points:30
-C, --context= 从可用的上下文中选择一个上下文
--session= 从可用的会话中选择一个会话
-S, --setup 为 fabric 的所有可重新配置部分运行设置
-t, --temperature= 设置 temperature 值(默认: 0.7)
-T, --topp= 设置 top P 值(默认: 0.9)
-s, --stream 流式传输
-P, --presencepenalty= 设置 presence penalty 值(默认: 0.0)
-r, --raw 使用模型的默认设置,不发送聊天选项(例如 temperature 等),并使用用户角色而非系统角色来匹配模式
-F, --frequencypenalty= 设置 frequency penalty 值(默认: 0.0)
-l, --listpatterns 列出所有模式
-L, --listmodels 列出所有可用的模型
-x, --listcontexts 列出所有上下文
-X, --listsessions 列出所有会话
-U, --updatepatterns 更新模式
-c, --copy 复制到剪贴板
-m, --model= 选择模型
-o, --output= 输出到文件
--output-session 将整个会话(包括临时会话)输出到文件
-n, --latest= 列出最近的模式数量(默认: 0)
-d, --changeDefaultModel 更改默认模型
-y, --youtube= 指定 YouTube 视频 "URL",以从中抓取转录内容和评论并发送到聊天
--transcript 从 YouTube 视频抓取转录内容并发送到聊天(默认使用此选项)
--comments 从 YouTube 视频抓取评论并发送到聊天
-g, --language= 指定聊天的语言代码,例如 -g=en -g=zh
-u, --scrape_url= 使用 Jina AI 将网站 URL 转换为 Markdown 格式
-q, --scrape_question= 使用 Jina AI 搜索问题
-e, --seed= 为 LMM 生成指定种子
-w, --wipecontext= 清除上下文
-W, --wipesession= 清除会话
--printcontext= 打印上下文
--printsession= 打印会话
--readability 将 HTML 输入转换为干净的可读视图
--dry-run 显示将发送给模型的内容而不实际发送
--version 打印当前版本

帮助选项:
-h, --help 显示此帮助信息

 

Practice Recommendations

Users are advised to try different features in practice to better understand the power of Fabric. With practice, you will be able to fully utilize this tool to improve productivity and learning.

Next, our instructions are very clearWe use Markdown structures to emphasize what we want the AI to do and in what order. Example: https://github.com/danielmiessler/fabric/blob/main/patterns/extract_wisdom/system.md

fabric also provides a prompt template, you can refer to this structure to easily write high-quality and stable prompt:.

https://github.com/danielmiessler/fabric/tree/main/patterns/create_pattern

 

Finally, we tend to use the System part of Prompt almost exclusively. For over a year now, we've been burying our heads in the sand on these things, and we're just now seeing more of the effects of doing so. If things change, or if we see data that suggests otherwise, we will make adjustments.

 

(for) instance

Now let's look at some of the things you can do with Fabric.

  1. Run the summarize mode based on the input of stdin. In this case, the body of the article.
pbpaste | fabric --pattern summarize
  1. 使用 –stream 选项运行 analyze_claims 模式,以获得即时和流式处理结果。
pbpaste | fabric --stream --pattern analyze_claims
  1. 使用 –stream 选项运行 extract_wisdom 模式,以从任何 Youtube 视频中获取即时和流式结果(与原始介绍视频非常相似)。
fabric -y "https://youtube.com/watch?v=uXs-zPc63kM" --stream --pattern extract_wisdom
  1. 创建图案 – 您必须使用该图案创建一个 .md 文件并将其保存到 ~/.config/fabric/patterns/[yourpatternname]。

 

Just copy it out and use it. If you don't want to do anything fancy and just want lots of great tips, you can navigate to the /patterns directoryAnd start exploring! All modular cue words are under this path, easy to use, no need to write code: there is a system.md in each word directory, the

0Bookmarked
0kudos

Recommended

Can't find AI tools? Try here!

Just type in the keyword Accessibility Bing SearchYou can quickly find all the AI tools on this site.

inbox

Contact Us

Top

en_USEnglish