| name | cnki-advanced-search |
| description | Perform advanced search on CNKI with field filters like author, title, journal, date range, source category (SCI/EI/CSSCI/北大核心). Use when user needs precise filtered search beyond simple keywords. |
| argument-hint | [describe search criteria in natural language] |
CNKI Advanced Search (高级检索)
RC browser tool: navigate with browser action=open url="..."; run the JS in each step via browser action=act kind=evaluate fn="<the async function shown>" (the whole function body goes into fn). Never pass a profile — RC uses its default managed Chrome (CDP 18800).
Perform a filtered search on CNKI using the old-style advanced search interface (only interface with source category checkboxes).
Arguments
$ARGUMENTS describes the search criteria in natural language. Parse it to identify:
- Subject keywords (主题) — default field
- Title keywords (篇名)
- Keywords (关键词)
- Author name (作者) — separate field
#au_1_value1
- Journal/source (文献来源) — separate field
#magazine_value1
- Date range (时间范围) —
#startYear / #endYear
- Source category (来源类别:SCI, EI, 北大核心, CSSCI, CSCD)
Steps
1. Navigate
Use browser action=open → https://kns.cnki.net/kns/AdvSearch?classid=7NS01R8M
2. Search + get results (single async browser act kind=evaluate)
Replace placeholder values with actual search criteria:
async () => {
const query = "KEYWORDS";
const fieldType = "SU";
const query2 = "";
const fieldType2 = "KY";
const rowLogic = "AND";
const sourceTypes = ["CSSCI"];
const startYear = "";
const endYear = "";
const author = "";
const journal = "";
await new Promise((r, j) => {
let n = 0;
const c = () => { if (document.querySelector('#txt_1_value1')) (); (n++ > ) (); (c, ); };
();
});
cap = .();
(cap && cap.(). >= ) { : };
selects = .(.()).( s. !== );
(sourceTypes. > ) {
gjAll = .();
(gjAll && gjAll.) gjAll.();
( st sourceTypes) {
cb = .( + st);
(cb && !cb.) cb.();
}
}
selects[]. = fieldType;
selects[].( (, { : }));
input = .();
input. = query;
input.( (, { : }));
(query2) {
selects[]. = rowLogic;
selects[].( (, { : }));
selects[]. = fieldType2;
selects[].( (, { : }));
input2 = .();
input2. = query2;
input2.( (, { : }));
}
(author) {
auInput = .();
(auInput) { auInput. = author; auInput.( (, { : })); }
}
(journal) {
magInput = .();
(magInput) { magInput. = journal; magInput.( (, { : })); }
}
(startYear) { selects[]. = startYear; selects[].( (, { : })); }
(endYear) { selects[]. = endYear; selects[].( (, { : })); }
.()?.();
( {
n = ;
= () => {
(...()) ();
(n++ > ) ();
(c, );
};
(c, );
});
cap2 = .();
(cap2 && cap2.(). >= ) { : };
{
query, fieldType, query2, fieldType2, rowLogic,
sourceTypes, startYear, endYear, author, journal,
: .()?.?.()?.[] || ,
: .()?. || ,
: location.
};
}
3. Report
Advanced search: "{query}" ({fieldType}) + source: {sourceTypes} → {total} results.
Tool calls: 2 (navigate + browser act kind=evaluate)
Verified selectors (old-style interface)
Form fields
| Element | Selector / Select index | Notes |
|---|
| 行1 字段类型 | selects[0] | SU=主题, TI=篇名, KY=关键词, TKA=篇关摘, AB=摘要 |
| 行1 关键词 | #txt_1_value1 | main keyword input |
| 行1 行内第二词 | #txt_1_value2 | same-row AND/OR/NOT with first keyword |
| 行1 行内逻辑 | selects[2] | AND=并含, OR=或含, NOT=不含 |
| 行间逻辑 | selects[5] | AND=并且, OR=或者, NOT=不含 |
| 行2 字段类型 | selects[6] | same options as row 1 |
| 行2 关键词 | #txt_2_value1 | second row keyword |
| 行2 行内第二词 | #txt_2_value2 | |
| 作者 | #au_1_value1 | placeholder "中文名/英文名/拼音" |
| 作者单位 | #au_1_value2 | placeholder "全称/简称/曾用名" |
| 文献来源 | #magazine_value1 | placeholder "期刊名称/ISSN/CN" |
| 基金 | #base_value1 | |
| 起始年 | selects[14] / #startYear | <select> 1915-2026 |
| 结束年 | selects[15] / #endYear | <select> 2026-1915 |
| 检索按钮 | div.search | NOT input/button |
Source type checkboxes (来源类型)
| 来源 | Checkbox ID | Notes |
|---|
| 全部期刊 | #gjAll | 默认勾选,选其他前需取消 |
| SCI来源期刊 | #SCI | value="Y" |
| EI来源期刊 | #EI | value="Y" |
| 北大核心期刊 | #hx | value="Y" |
| CSSCI | #CSSCI | value="Y" |
| CSCD | #CSCD | value="Y" |
Multiple source types can be checked simultaneously (OR logic).
Results
| Element | Selector | Notes |
|---|
| Result count | .pagerTitleCell | text "共找到 X 条结果" |
| Page indicator | .countPageMark | text "1/300" |
Captcha detection
Check #tcaptcha_transform_dy element's getBoundingClientRect().top >= 0.
Important Notes
- Must use old-style URL (
kns.cnki.net/kns/AdvSearch). New interface (kns8s/AdvSearch) has NO source category checkboxes.
- The
classid=7NS01R8M parameter ensures the correct form layout loads.
- Results page is compatible with
cnki-parse-results and cnki-navigate-pages skills.