> ## Documentation Index
> Fetch the complete documentation index at: https://aisa.one/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# 智能搜索

> 同时搜索网页与学术来源，适合跨在两边的问题。

同时搜索网页与学术来源，适合跨在两边的问题。⚠️ 参数放在 **query string** 里：`query`（必填）、`max_num_results`、`as_ylo`/`as_yhi`。返回一个检索 `id` 和 `results[]`；**条目形状随来源变化** —— 每条都有 `title`、`link`、`snippet`，学术来源的还额外带 `authors` 和 `number_of_citations`，所以把这两个字段当作可选的，不要默认它们存在。实测约 3 秒。当你事先不知道哪类来源能回答时用它。已经知道的话，[`post_scholar_search_web`](/docs/zh/api-reference/scholar/post_scholar-search-web) 或 [`post_scholar_search_scholar`](/docs/zh/api-reference/scholar/post_scholar-search-scholar) 的返回更可预期。记住 `id`，[`post_scholar_search_explain`](/docs/zh/api-reference/scholar/post_scholar-search-explain) 要用。

<Note>
  **第一次用？** 把任意 MCP 客户端指向 `https://mcp.aisa.one/mcp` —— Claude Code、
  Codex、Cursor、VS Code 都可以。鉴权走 OAuth：客户端打开浏览器，你点一次
  Allow，不需要粘贴任何 key。各客户端的具体命令和每次调用的价格见
  [aisa.one/zh-cn/mcp](https://aisa.one/zh-cn/mcp#connect)。
</Note>

[在你的 agent 里把这个端点跑起来 →](https://aisa.one/mcp?from=/zh/api-reference/scholar/post_scholar-search-mixed)


## OpenAPI

````yaml openapi/zh/platform-txyz-openapi.json POST /scholar/search/mixed
openapi: 3.0.0
info:
  title: TXYZ Platform API
  version: 1.0.0
  description: platform.txyz.ai 服务的 API 文档，包括学术搜索功能
  contact:
    email: support@txyz.ai
  license:
    name: Proprietary
servers:
  - url: https://api.aisa.one/apis/v1
security:
  - BearerAuth: []
paths:
  /scholar/search/mixed:
    post:
      tags:
        - Search
        - Smart
      summary: 结合网页和学术结果的智能搜索
      description: >-
        同时搜索网页与学术来源，适合跨在两边的问题。⚠️ 参数放在 **query string**
        里：`query`（必填）、`max_num_results`、`as_ylo`/`as_yhi`。返回一个检索 `id` 和
        `results[]`；**条目形状随来源变化** —— 每条都有 `title`、`link`、`snippet`，学术来源的还额外带
        `authors` 和 `number_of_citations`，所以把这两个字段当作可选的，不要默认它们存在。实测约 3
        秒。当你事先不知道哪类来源能回答时用它。已经知道的话，`post_scholar_search_web` 或
        `post_scholar_search_scholar` 的返回更可预期。记住
        `id`，`post_scholar_search_explain` 要用。
      operationId: post_scholar_search_mixed
      parameters:
        - name: query
          in: query
          required: true
          description: 学术资料搜索查询
          schema:
            type: string
            example: machine learning
        - name: max_num_results
          in: query
          description: 返回的搜索结果最大数量，最多 100 条
          schema:
            type: integer
            minimum: 1
            maximum: 100
            default: 10
        - name: as_ylo
          in: query
          description: 出版年份下限
          schema:
            type: integer
            nullable: true
            minimum: 1900
            maximum: 2030
        - name: as_yhi
          in: query
          description: 出版年份上限
          schema:
            type: integer
            nullable: true
            minimum: 1900
            maximum: 2030
      responses:
        '200':
          description: 搜索成功响应
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SmartSearchResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '429':
          $ref: '#/components/responses/TooManyRequests'
        '500':
          $ref: '#/components/responses/InternalError'
      security:
        - BearerAuth: []
components:
  schemas:
    SmartSearchResponse:
      type: object
      required:
        - id
        - results
      properties:
        id:
          type: string
          description: 搜索请求的唯一标识符
        results:
          type: array
          items:
            $ref: '#/components/schemas/SmartResult'
          description: 融合网页和学术内容的智能搜索结果列表
        search_type:
          type: string
          enum:
            - web
            - academic
            - hybrid
          description: 包含的搜索结果类型
    SmartResult:
      type: object
      required:
        - title
        - link
        - snippet
      properties:
        title:
          type: string
          description: 结果标题
        link:
          type: string
          format: uri
          description: 用于访问内容的 URL
        snippet:
          type: string
          description: 简要摘要
        authors:
          type: array
          items:
            type: string
          description: 作者列表（用于学术内容）
        number_of_citations:
          type: integer
          minimum: 0
          description: 引用数量（针对学术内容）
        type:
          type: string
          enum:
            - web
            - academic
          description: 结果类型
        relevance_score:
          type: number
          minimum: 0
          maximum: 1
          description: 结果的相关性评分
    ErrorResponse:
      type: object
      properties:
        error:
          type: string
          description: 描述错误原因的错误消息
        code:
          type: integer
          description: HTTP 状态码
        details:
          type: string
          description: 其他错误详情
  responses:
    BadRequest:
      description: 错误请求 - 参数无效
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
    Unauthorized:
      description: 未授权 - API 密钥无效或缺失
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
    TooManyRequests:
      description: 超出速率限制
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
    InternalError:
      description: 内部服务器错误
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.