Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feature/SPRIND-83 #267

Merged
merged 32 commits into from
Nov 22, 2024
Merged

feature/SPRIND-83 #267

merged 32 commits into from
Nov 22, 2024

Conversation

zoemaas
Copy link
Contributor

@zoemaas zoemaas commented Nov 7, 2024

No description provided.

@zoemaas zoemaas self-assigned this Nov 7, 2024
@zoemaas zoemaas marked this pull request as ready for review November 7, 2024 16:27
Zoë Maas and others added 22 commits November 11, 2024 23:34
 into feature/SPRIND-83

# Conflicts:
#	pnpm-lock.yaml
 into feature/SPRIND-83

# Conflicts:
#	pnpm-lock.yaml
…ource/SSI-SDK into feature/SPRIND-83_test

# Conflicts:
#	packages/anomaly-detection/src/agent/AnomalyDetection.ts
# Conflicts:
#	packages/tsconfig.json
#	pnpm-lock.yaml
Copy link
Contributor

@sanderPostma sanderPostma left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Found bad import

@@ -0,0 +1,16 @@
import {IAgentContext, IPluginMethodMap} from '@veramo/core'
import {AnomalyDetectionStoreArgs, IAnomalyDetectionStore} from "@sphereon/ssi-sdk.anomaly-detection-store";
import {Optional} from "nx/src/project-graph/plugins";
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/src import

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like a mixed it up with Java 🙈

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Replaced it with a Partial

Copy link
Contributor

@sanderPostma sanderPostma left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM when import is fixed.
When this is not possible for some reason, add a comment

@zoemaas zoemaas merged commit e387a81 into develop Nov 22, 2024
2 checks passed
@zoemaas zoemaas deleted the feature/SPRIND-83 branch November 22, 2024 13:55

---

A Veramo anomaly detection store plugin. This plugin stores the result of the location lookup which is part of the anomaly detection plugin
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please stop using the word Veramo everywhere. This really is not a Veramo plugin

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Replaced Veramo with Sphereon


const agent = createAgent<IAnomalyDetectionStore>({
plugins: [
new AnomalyDetectionStore({
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be renamed to GeoLocationStore

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

geolocation is a single word: https://dictionary.cambridge.org/dictionary/english/geolocation. Doesn't it make more sense to rename it to GeolocationStore?

### Lookup a location:

```typescript
const result = await agent.lookupLocation({
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agent plugin should prefix something, to ensure that a developer can actually make head or tails about the 100+ methods available in a plugin.

So geoLookupLocation makes sense

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

geolocation is a single word: https://dictionary.cambridge.org/dictionary/english/geolocation. If we want to prefix the method with geo, doesn't it make more sense to call it geolocationLookup?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes

/**
* {@inheritDoc IAnomalyDetectionStore}
*/
export class AnomalyDetectionStore implements IAgentPlugin {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please rename to GeoLocationStore. This is only about Geo locations, which happens to be part of anomaly detection. We will not store other data in this plugin in the future.

So rename the class and also this store plugin. But do not rename the anomaly-detection plugin itself. That just uses the renamed GeoLocationStore module/plugin

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

geolocation is a single word: https://dictionary.cambridge.org/dictionary/english/geolocation. Doesn't it make more sense to rename it to GeolocationStore?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

of course

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants