• podman-compose启动报错missing networks default

    Q: macos上,podman-compose启动失败,报错 “RuntimeError: missing networks: default” A: 根据搜索结果,Podman Compose 在某些情况下无法自动创建默认网络,需要在 docker-compose.yml 文件中显式定义默认网络。例如: version: '3.8' services: your_service: image: your_image networks: - default networks: default: driver: bridge

  • 从零构建向量数据库与相似度搜索

    https://medium.com/@vidiptvashist/building-a-vector-database-from-scratch-in-python-6bd683ba5171 关键还是如何做 embedding。以及如何做相似度计算? 后面看一下有哪些常用的embedding model 和算法。 还有,代码中都是简单的字符串,如果特别长,怎么切片呢?这个参数是不是也重要? from typing import Any import numpy as np class VectorStore: def __init__(self): self.vector_data: dict[str, np.ndarray] = {} # A dictionary to store vectors...

  • 这不是有效沟通

    A: Deepseek 为什么成本这么低? B:我不懂。 A:你不懂?你们搞技术的应该都懂啊。 B:我不懂。 A:那你懂啥?

  • 深度神经网络中的残差连接原理

    In conclusion, shortcut connections are important for overcoming the limitations posed by the vanishing gradient problem in deep neural networks. Shortcut connections are a core building block of very large...

  • 认错

    我觉得人生过的顺畅一些的一个改变是,把第一反应从辩解(缺少正确逻辑的辩解)变成认错。

  • 从零构建LLM学习笔记二:多头注意力机制

    需要看pytorch的文档,进一步了解里面第一步的作用是什么,以了解MultiHeadAttention的原理 class MultiHeadAttention(nn.Module): def __init__(self, d_in, d_out, context_length, dropout, num_heads, qkv_bias=False): super().__init__() assert d_out % num_heads == 0, "d_out must be divisible by num_heads" self.d_out = d_out self.num_heads = num_heads...

  • 从零构建LLM学习笔记一:token到向量嵌入

    一句话,像"I am a student.",am 的 tokenID 是一个[xx,xx,xx]这样的“三维”向量。第书的第二章讲的encode token,是变成一个数字,怎么到了第三章,突然成了一个三维向量?中间发生了哪些操作? 在第三章的“Implementing self-attention with trainable weights”这一节,说到“我们成功将6个输入标记从三维投影到二维嵌入空间上”。为什么要把三维转成二维?这里说的“embedding space”又是指什么?

  • git fetch拉取PR到本地分支

    git fetch origin pull/265/head:pr-265

  • GitHub Pages配合Cloudflare SSL死循环301问题

    将 GitHub Pages 的自定义域名迁到 cloudflare 之后,一直死循环 301。 原因是,cloudflare 默认的 SSL 配置是 “灵活”:仅在访问者与 Cloudflare 之间启用加密。这可以避免浏览器发出安全警告,但 Cloudflare 与您的源服务器之间的所有连接均通过 HTTP 建立。 而我的 github pages 配置了 enforce https,所以就会出现死循环。 但是,还有一个github pages 项目使用不能配置 enforce https,配置页面显示”Enforce HTTPS...

  • AutoGen SelectorGroupChat的participants参数含义

    autogen里面的一段代码如下: selector_group_chat = SelectorGroupChat( [add_agent, multiply_agent, subtract_agent, divide_agent, identity_agent], model_client=OpenAIChatCompletionClient(model="gpt-4o"), termination_condition=termination_condition, allow_repeated_speaker=True, # Allow the same agent to speak multiple times, necessary for this task. selector_prompt=( "Available roles:\n{roles}\nTheir job descriptions:\n{participants}\n"...