@cool-digital-solutions/interferir-models 1.3.33 → 1.3.34

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -7,13 +7,28 @@ const mongoose_1 = require("mongoose");
7
7
  const express_http_context_1 = __importDefault(require("express-http-context"));
8
8
  const _config_1 = require("../config");
9
9
  const visionBoardSchema = new mongoose_1.Schema({
10
- companyId: { type: String, required: true },
10
+ companyId: { type: mongoose_1.Schema.Types.ObjectId, ref: 'Company' },
11
11
  companyName: { type: String },
12
12
  reportTitle: { type: String },
13
13
  researchDate: { type: Number, required: true },
14
+ sections: [
15
+ {
16
+ aiTaskOutlineId: { type: mongoose_1.Schema.Types.ObjectId, ref: 'AiTaskOutline' },
17
+ content: { type: String },
18
+ references: [
19
+ {
20
+ url: { type: String },
21
+ citationNumber: { type: Number },
22
+ },
23
+ ],
24
+ sectionNumber: { type: String },
25
+ sectionType: { type: String },
26
+ title: { type: String },
27
+ },
28
+ ],
14
29
  useCaseList: [
15
30
  {
16
- id: { type: String, required: true },
31
+ id: { type: mongoose_1.Schema.Types.ObjectId, ref: 'UseCase', required: true },
17
32
  title: { type: String, required: true },
18
33
  description: { type: String },
19
34
  url: { type: String, required: true },
@@ -26,7 +41,7 @@ const visionBoardSchema = new mongoose_1.Schema({
26
41
  ],
27
42
  startups: [
28
43
  {
29
- id: { type: String, required: true },
44
+ id: { type: mongoose_1.Schema.Types.ObjectId, ref: 'Company', required: true },
30
45
  name: { type: String },
31
46
  foundingYear: { type: Number, default: 0 },
32
47
  location: { type: String },
@@ -41,19 +56,19 @@ const visionBoardSchema = new mongoose_1.Schema({
41
56
  ],
42
57
  superUsecases: [
43
58
  {
44
- id: { type: String, required: true },
59
+ id: { type: mongoose_1.Schema.Types.ObjectId, ref: 'UseCase', required: true },
45
60
  title: { type: String },
46
61
  description: { type: String },
47
62
  content: { type: String },
48
63
  differentiationFactors: [String],
49
64
  maturityLevel: { type: String },
50
65
  potentialImpact: { type: String },
51
- relatedUseCaseId: { type: String },
66
+ relatedUseCaseId: { type: mongoose_1.Schema.Types.ObjectId, ref: 'UseCase' },
52
67
  },
53
68
  ],
54
69
  keyCompetitors: [
55
70
  {
56
- id: { type: String },
71
+ id: { type: mongoose_1.Schema.Types.ObjectId, ref: 'Company' },
57
72
  name: { type: String },
58
73
  industryPosition: { type: String },
59
74
  marketShare: { type: String },
@@ -63,7 +78,7 @@ const visionBoardSchema = new mongoose_1.Schema({
63
78
  ],
64
79
  keyCustomers: [
65
80
  {
66
- id: { type: String },
81
+ id: { type: mongoose_1.Schema.Types.ObjectId, ref: 'Company' },
67
82
  name: { type: String },
68
83
  industry: { type: String },
69
84
  relationshipLength: { type: String },
@@ -73,7 +88,7 @@ const visionBoardSchema = new mongoose_1.Schema({
73
88
  ],
74
89
  clientActivities: [
75
90
  {
76
- id: { type: String },
91
+ id: { type: mongoose_1.Schema.Types.ObjectId, ref: 'Company' },
77
92
  customerName: { type: String },
78
93
  activityType: { type: String },
79
94
  description: { type: String },
@@ -85,7 +100,7 @@ const visionBoardSchema = new mongoose_1.Schema({
85
100
  ],
86
101
  competitorActivities: [
87
102
  {
88
- id: { type: String },
103
+ id: { type: mongoose_1.Schema.Types.ObjectId, ref: 'Company' },
89
104
  competitorName: { type: String },
90
105
  activityType: { type: String },
91
106
  description: { type: String },
@@ -93,16 +108,16 @@ const visionBoardSchema = new mongoose_1.Schema({
93
108
  date: { type: Number },
94
109
  marketImpact: { type: String },
95
110
  technologiesInvolved: [String],
96
- caterpillarResponseNeeded: { type: String },
111
+ responseNeeded: { type: String },
97
112
  },
98
113
  ],
99
114
  news: [
100
115
  {
101
- id: { type: String },
116
+ id: { type: mongoose_1.Schema.Types.ObjectId, ref: 'PortiaArticle' },
102
117
  date: { type: Number },
103
118
  headline: { type: String },
104
119
  source: { type: String },
105
- impactOnCaterpillar: { type: String },
120
+ impact: { type: String },
106
121
  recommendedResponse: { type: String },
107
122
  importance: { type: String },
108
123
  content: { type: String },
@@ -115,7 +130,7 @@ const visionBoardSchema = new mongoose_1.Schema({
115
130
  title: { type: String },
116
131
  description: { type: String },
117
132
  geographicalScope: { type: String },
118
- impactOnCaterpillar: { type: String },
133
+ impact: { type: String },
119
134
  complianceDeadline: { type: Number },
120
135
  complianceCostEstimate: { type: String },
121
136
  content: { type: String },
@@ -123,7 +138,7 @@ const visionBoardSchema = new mongoose_1.Schema({
123
138
  ],
124
139
  marketData: {
125
140
  totalAddressableMarket: { type: String },
126
- caterpillarMarketShare: { type: String },
141
+ marketShare: { type: String },
127
142
  marketGrowthRate: { type: String },
128
143
  segmentBreakdown: [
129
144
  {
@@ -131,27 +146,27 @@ const visionBoardSchema = new mongoose_1.Schema({
131
146
  segment: { type: String },
132
147
  marketSize: { type: String },
133
148
  growthRate: { type: String },
134
- caterpillarShare: { type: String },
149
+ share: { type: String },
135
150
  },
136
151
  ],
137
152
  technologyAdoptionTrends: [
138
153
  {
139
- id: { type: String },
154
+ id: { type: mongoose_1.Schema.Types.ObjectId, ref: 'Technology' },
140
155
  technology: { type: String },
141
156
  currentAdoption: { type: String },
142
- fiveYearProjection: { type: String }, // Renamed from "5_year_projection"
143
- caterpillarReadiness: { type: String },
157
+ fiveYearProjection: { type: String },
158
+ readiness: { type: String },
144
159
  },
145
160
  ],
146
161
  },
147
162
  focusAreasOfUseCases: [
148
163
  {
149
- id: { type: String },
164
+ id: { type: mongoose_1.Schema.Types.ObjectId, ref: 'UseCase' },
150
165
  focusArea: { type: String },
151
166
  description: { type: String },
152
167
  content: { type: String },
153
168
  strategicImportance: { type: String },
154
- relatedUseCaseIds: [String],
169
+ relatedUseCaseIds: [{ type: mongoose_1.Schema.Types.ObjectId, ref: 'UseCase' }],
155
170
  investmentRecommendation: { type: String },
156
171
  expectedRoi: { type: String },
157
172
  },
@@ -1,6 +1,43 @@
1
+ /// <reference types="mongoose/types/aggregate" />
2
+ /// <reference types="mongoose/types/callback" />
3
+ /// <reference types="mongoose/types/collection" />
4
+ /// <reference types="mongoose/types/connection" />
5
+ /// <reference types="mongoose/types/cursor" />
6
+ /// <reference types="mongoose/types/document" />
7
+ /// <reference types="mongoose/types/error" />
8
+ /// <reference types="mongoose/types/expressions" />
9
+ /// <reference types="mongoose/types/helpers" />
10
+ /// <reference types="mongoose/types/middlewares" />
11
+ /// <reference types="mongoose/types/indexes" />
12
+ /// <reference types="mongoose/types/models" />
13
+ /// <reference types="mongoose/types/mongooseoptions" />
14
+ /// <reference types="mongoose/types/pipelinestage" />
15
+ /// <reference types="mongoose/types/populate" />
16
+ /// <reference types="mongoose/types/query" />
17
+ /// <reference types="mongoose/types/schemaoptions" />
18
+ /// <reference types="mongoose/types/schematypes" />
19
+ /// <reference types="mongoose/types/session" />
20
+ /// <reference types="mongoose/types/types" />
21
+ /// <reference types="mongoose/types/utility" />
22
+ /// <reference types="mongoose/types/validation" />
23
+ /// <reference types="mongoose/types/virtuals" />
24
+ /// <reference types="mongoose/types/inferschematype" />
25
+ import { Types } from 'mongoose';
1
26
  import { BaseModel, BaseSchema } from '../config';
27
+ export interface Reference {
28
+ url?: string;
29
+ citationNumber?: number;
30
+ }
31
+ export interface Section {
32
+ aiTaskOutlineId?: string;
33
+ content?: string;
34
+ references?: Reference[];
35
+ sectionNumber?: string;
36
+ sectionType?: string;
37
+ title?: string;
38
+ }
2
39
  export interface UseCase {
3
- id: string;
40
+ id: Types.ObjectId;
4
41
  title: string;
5
42
  description?: string;
6
43
  url: string;
@@ -11,17 +48,17 @@ export interface UseCase {
11
48
  potentialValue?: string;
12
49
  }
13
50
  export interface SuperUseCase {
14
- id: string;
51
+ id: Types.ObjectId;
15
52
  title?: string;
16
53
  description?: string;
17
54
  content?: string;
18
55
  differentiationFactors?: string[];
19
56
  maturityLevel?: string;
20
57
  potentialImpact?: string;
21
- relatedUseCaseId?: string;
58
+ relatedUseCaseId?: Types.ObjectId;
22
59
  }
23
60
  export interface Startup {
24
- id: string;
61
+ id: Types.ObjectId;
25
62
  name?: string;
26
63
  foundingYear?: number;
27
64
  location?: string;
@@ -34,7 +71,7 @@ export interface Startup {
34
71
  content?: string;
35
72
  }
36
73
  export interface Competitor {
37
- id?: string;
74
+ id?: Types.ObjectId;
38
75
  name?: string;
39
76
  industryPosition?: string;
40
77
  marketShare?: string;
@@ -42,7 +79,7 @@ export interface Competitor {
42
79
  weaknesses?: string[];
43
80
  }
44
81
  export interface Customer {
45
- id?: string;
82
+ id?: Types.ObjectId;
46
83
  name?: string;
47
84
  industry?: string;
48
85
  relationshipLength?: string;
@@ -50,7 +87,7 @@ export interface Customer {
50
87
  strategicImportance?: string;
51
88
  }
52
89
  export interface ClientActivity {
53
- id?: string;
90
+ id?: Types.ObjectId;
54
91
  customerName?: string;
55
92
  activityType?: string;
56
93
  description?: string;
@@ -60,7 +97,7 @@ export interface ClientActivity {
60
97
  strategicRelevance?: string;
61
98
  }
62
99
  export interface CompetitorActivity {
63
- id?: string;
100
+ id?: Types.ObjectId;
64
101
  competitorName?: string;
65
102
  activityType?: string;
66
103
  description?: string;
@@ -68,14 +105,14 @@ export interface CompetitorActivity {
68
105
  date?: number;
69
106
  marketImpact?: string;
70
107
  technologiesInvolved?: string[];
71
- caterpillarResponseNeeded?: string;
108
+ responseNeeded?: string;
72
109
  }
73
110
  export interface News {
74
- id?: string;
111
+ id?: Types.ObjectId;
75
112
  date?: number;
76
113
  headline?: string;
77
114
  source?: string;
78
- impactOnCaterpillar?: string;
115
+ impact?: string;
79
116
  recommendedResponse?: string;
80
117
  importance?: string;
81
118
  content?: string;
@@ -86,7 +123,7 @@ export interface Regulation {
86
123
  title?: string;
87
124
  description?: string;
88
125
  geographicalScope?: string;
89
- impactOnCaterpillar?: string;
126
+ impact?: string;
90
127
  complianceDeadline?: number;
91
128
  complianceCostEstimate?: string;
92
129
  content?: string;
@@ -96,28 +133,28 @@ export interface Segment {
96
133
  segment?: string;
97
134
  marketSize?: string;
98
135
  growthRate?: string;
99
- caterpillarShare?: string;
136
+ share?: string;
100
137
  }
101
138
  export interface Trend {
102
- id?: string;
139
+ id?: Types.ObjectId;
103
140
  technology?: string;
104
141
  currentAdoption?: string;
105
142
  fiveYearProjection?: string;
106
- caterpillarReadiness?: string;
143
+ readiness?: string;
107
144
  }
108
145
  export interface FocusArea {
109
- id?: string;
146
+ id?: Types.ObjectId;
110
147
  focusArea?: string;
111
148
  description?: string;
112
149
  content?: string;
113
150
  strategicImportance?: string;
114
- relatedUseCaseIds?: string[];
151
+ relatedUseCaseIds?: Types.ObjectId[];
115
152
  investmentRecommendation?: string;
116
153
  expectedRoi?: string;
117
154
  }
118
155
  export interface MarketData {
119
156
  totalAddressableMarket?: string;
120
- caterpillarMarketShare?: string;
157
+ marketShare?: string;
121
158
  marketGrowthRate?: string;
122
159
  segmentBreakdown?: Segment[];
123
160
  technologyAdoptionTrends?: Trend[];
@@ -130,10 +167,11 @@ export interface Metadata {
130
167
  aitaskId?: string;
131
168
  }
132
169
  export interface IVisionBoard extends BaseSchema {
133
- companyId: string;
170
+ companyId: Types.ObjectId;
134
171
  companyName?: string;
135
172
  reportTitle?: string;
136
173
  researchDate: number;
174
+ sections?: Section[];
137
175
  useCaseList: UseCase[];
138
176
  startups?: Startup[];
139
177
  superUsecases: SuperUseCase[];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cool-digital-solutions/interferir-models",
3
- "version": "1.3.33",
3
+ "version": "1.3.34",
4
4
  "main": "./dist/index.js",
5
5
  "files": [
6
6
  "dist/**/*"