microsoft / botframework-cli
Duplication

Places in code with 6 or more lines that are exactly the same.

Intro
  • For duplication, we look at places in code where there are 6 or more lines of code that are exactly the same.
  • Before duplication is calculated, the code is cleaned to remove empty lines, comments, and frequently duplicated constructs such as imports.
  • You should aim at having as little as possible (<5%) of duplicated code as high-level of duplication can lead to maintenance difficulties, poor factoring, and logical contradictions.
Learn more...
Duplication Overall
  • 25% duplication:
    • 58,120 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 14,828 duplicated lines
  • 3,430 duplicates
system25% (14,828 lines)
Duplication per Extension
ts32% (13,446 lines)
yaml12% (1,018 lines)
js3% (324 lines)
yml22% (40 lines)
Duplication per Component (primary)
packages/dispatcher36% (8,214 lines)
packages/orchestratorlib39% (4,263 lines)
common/config12% (1,018 lines)
packages/lu6% (566 lines)
packages/luis20% (312 lines)
packages/qnamaker11% (162 lines)
packages/orchestrator23% (143 lines)
build22% (40 lines)
packages/chatdown6% (39 lines)
packages/lg4% (29 lines)
packages/command13% (23 lines)
common/scripts2% (12 lines)
packages/dialog<1% (7 lines)
packages/cli0% (0 lines)
packages/config0% (0 lines)
packages/plugins0% (0 lines)
scripts0% (0 lines)

Duplication Between Components (50+ lines)

G packages/dispatcher packages/dispatcher packages/orchestratorlib packages/orchestratorlib packages/dispatcher--packages/orchestratorlib 1094 packages/luis packages/luis packages/qnamaker packages/qnamaker packages/luis--packages/qnamaker 220 packages/chatdown packages/chatdown packages/lu packages/lu packages/chatdown--packages/lu 78 packages/lu--packages/luis 64

Download: SVG DOT (open online Graphviz editor)

Open 3D force graph...

Show more details on duplication between components...
Longest Duplicates
The list of 20 longest duplicates.
See data for all 3,430 duplicates...
Size#FoldersFilesLinesCode
105 x 2 packages/dispatcher/src/...uation/cross_validation
packages/dispatcher/src/model/evaluation/predict
CrossValidator.ts
Predictor.ts
236:340 (17%)
175:279 (30%)
view
63 x 2 packages/orchestratorlib/src/resources
packages/orchestratorlib/src/resources
assessment-label-summary-template-htm...
evaluation-summary-template-html.ts
7:81 (29%)
7:81 (33%)
view
52 x 2 packages/orchestratorlib/src
packages/orchestratorlib/src
predict.ts
predict.ts
144:195 (5%)
203:254 (5%)
view
51 x 2 packages/orchestratorlib/src
packages/orchestratorlib/src
evaluate.ts
test.ts
326:376 (15%)
324:374 (16%)
view
50 x 2 packages/orchestratorlib/src
packages/orchestratorlib/src
assess.ts
utility.ts
325:388 (19%)
366:429 (<1%)
view
50 x 2 packages/orchestratorlib/src
packages/orchestratorlib/src
assess.ts
utility.ts
222:285 (19%)
1068:1131 (<1%)
view
50 x 2 packages/orchestratorlib/src
packages/orchestratorlib/src
evaluate.ts
test.ts
227:276 (15%)
219:268 (15%)
view
49 x 2 packages/orchestratorlib/src
packages/orchestratorlib/src
utility.ts
utility.ts
2103:2151 (<1%)
2254:2302 (<1%)
view
48 x 2 packages/orchestratorlib/src
packages/orchestratorlib/src
utility.ts
utility.ts
2010:2057 (<1%)
2384:2431 (<1%)
view
48 x 2 packages/orchestratorlib/src
packages/orchestratorlib/src
evaluate.ts
utility.ts
226:273 (14%)
2058:2105 (<1%)
view
48 x 2 packages/orchestratorlib/src
packages/orchestratorlib/src
utility.ts
utility.ts
2054:2101 (<1%)
2205:2252 (<1%)
view
48 x 2 packages/orchestratorlib/src
packages/orchestratorlib/src
utility.ts
utility.ts
2161:2208 (<1%)
3290:3337 (<1%)
view
47 x 2 packages/orchestratorlib/src
packages/orchestratorlib/src
utility.ts
utility.ts
2210:2256 (<1%)
3290:3336 (<1%)
view
47 x 2 packages/orchestratorlib/src
packages/orchestratorlib/src
evaluate.ts
utility.ts
227:273 (14%)
2384:2430 (<1%)
view
47 x 2 packages/orchestratorlib/src
packages/orchestratorlib/src
evaluate.ts
utility.ts
227:273 (14%)
2010:2056 (<1%)
view
47 x 2 packages/orchestratorlib/src
packages/orchestratorlib/src
test.ts
utility.ts
219:265 (15%)
2059:2105 (<1%)
view
47 x 2 packages/orchestratorlib/src
packages/orchestratorlib/src
test.ts
utility.ts
219:265 (15%)
2010:2056 (<1%)
view
47 x 2 packages/orchestratorlib/src
packages/orchestratorlib/src
test.ts
utility.ts
219:265 (15%)
2384:2430 (<1%)
view
47 x 2 packages/orchestratorlib/src
packages/orchestratorlib/src
utility.ts
utility.ts
2010:2056 (<1%)
2059:2105 (<1%)
view
47 x 2 packages/orchestratorlib/src
packages/orchestratorlib/src
test.ts
utility.ts
325:371 (15%)
3290:3336 (<1%)
view
Duplicated Units
The list of top 20 duplicated units.
See data for all 40 unit duplicates...
Size#FoldersFilesLinesCode
39 x 2 packages/dispatcher/src/...matics/confusion_matrix
packages/dispatcher/src/...matics/confusion_matrix
MultiLabelConfusionMatrixExact.ts
MultiLabelObjectConfusionMatrixExact.ts
20:59 
63:102 
view
34 x 2 packages/dispatcher/src/...matics/confusion_matrix
packages/dispatcher/src/...matics/confusion_matrix
PerInstanceMultiLabelConfusionMatrix.ts
PerInstanceMultiLabelObjectConfusionM...
18:77 
46:104 
view
31 x 2 packages/dispatcher/src/data
packages/dispatcher/src/data
ColumnarData.ts
ColumnarDataWithSubwordFeaturizer.ts
182:214 
228:260 
view
28 x 2 packages/dispatcher/src/...matics/confusion_matrix
packages/dispatcher/src/...matics/confusion_matrix
MultiLabelConfusionMatrix.ts
MultiLabelObjectConfusionMatrix.ts
73:101 
56:84 
view
28 x 2 packages/dispatcher/src/...matics/confusion_matrix
packages/dispatcher/src/...matics/confusion_matrix
MultiLabelConfusionMatrixSubset.ts
MultiLabelObjectConfusionMatrixSubset.ts
20:48 
52:80 
view
22 x 2 packages/dispatcher/src/data
packages/dispatcher/src/data
EntityAnnotatedCorpusData.ts
EntityAnnotatedCorpusDataWithSubwordF...
153:176 
207:230 
view
22 x 2 packages/dispatcher/src/data
packages/dispatcher/src/data
LuData.ts
LuDataWithSubwordFeaturizer.ts
170:192 
201:223 
view
21 x 3 packages/chatdown/utils
packages/lu/src/parser/utils
packages/qnamaker/utils
httpsProxy.js
httpsProxy.js
httpsProxy.js
9:35 
9:35 
9:35 
view
20 x 2 packages/dispatcher/src/label_structure
packages/orchestratorlib/src
LabelStructureUtility.ts
utility.ts
658:678 
6347:6367 
view
15 x 2 packages/dispatcher/src/label_structure
packages/orchestratorlib/src
LabelStructureUtility.ts
orchestratorhelper.ts
705:720 
1093:1108 
view
15 x 2 packages/dispatcher/src/utility
packages/orchestratorlib/src
Utility.ts
utility.ts
1329:1344 
4861:4876 
view
15 x 2 packages/dispatcher/src/utility
packages/orchestratorlib/src
Utility.ts
utility.ts
2136:2151 
6686:6701 
view
14 x 3 packages/dispatcher/src/label_structure
packages/dispatcher/src/label_structure
packages/dispatcher/src/label_structure
ScoreEntityUtterancePrediction.ts
ScoreIntentUtterancePrediction.ts
ScoreLabelUtterancePrediction.ts
89:103 
53:67 
95:109 
view
14 x 2 packages/luis/src/commands/luis
packages/qnamaker/src/commands/qnamaker
translate.ts
translate.ts
96:110 
96:110 
view
13 x 2 packages/dispatcher/src/...matics/confusion_matrix
packages/dispatcher/src/...matics/confusion_matrix
MultiLabelConfusionMatrixWithBinaryBa...
MultiLabelObjectConfusionMatrixWithBi...
38:51 
38:51 
view
12 x 2 packages/dispatcher/src/...uation/cross_validation
packages/dispatcher/src/...er/auto_active_learning
CrossValidator.ts
AutoActiveLearner.ts
131:143 
107:119 
view
12 x 2 packages/dispatcher/src/model/evaluation/report
packages/dispatcher/src/model/evaluation/report
DataProfileReporter.ts
ModelMetaDataProfileReporter.ts
104:117 
93:106 
view
11 x 4 packages/dispatcher/src/...matics/confusion_matrix
packages/dispatcher/src/...matics/confusion_matrix
packages/dispatcher/src/...matics/confusion_matrix
packages/dispatcher/src/...matics/confusion_matrix
LabelObjectConfusionMatrix.ts
LabelObjectConfusionMatrixBase.ts
MultiLabelObjectConfusionMatrixBase.ts
PerInstanceMultiLabelObjectConfusionM...
37:48 
25:36 
47:58 
50:61 
view
11 x 2 packages/lu/src/parser/lu
packages/lu/src/parser/lu
lu.js
qna.js
11:23 
10:22 
view
10 x 2 packages/dispatcher/src/data_structure
packages/orchestratorlib/src
DictionaryMapUtility.ts
utility.ts
230:240 
6323:6333 
view